Differences From Artifact [f8c53776df]:
- File
src/OFUDPSocket.m
— part of check-in
[a54730b88f]
at
2022-10-22 18:41:45
on branch trunk
— OFSocket: Don't combine port for IP and IPX
While it works for those two protocols, it's a bad precedent as other
protocols have different types for ports. (user: js, size: 5117) [annotate] [blame] [check-ins using] [more...]
To Artifact [67c55bc52f]:
- File src/OFUDPSocket.m — part of check-in [64fc4f6344] at 2022-10-22 18:51:16 on branch trunk — Fix overlooked OFSocketAddress(Set)Port (user: js, size: 5119) [annotate] [blame] [check-ins using] [more...]
| ︙ | ︙ | |||
88 89 90 91 92 93 94 |
for (;;) {
uint16_t rnd = 0;
int ret;
while (rnd < 1024)
rnd = (uint16_t)rand();
| | | 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 |
for (;;) {
uint16_t rnd = 0;
int ret;
while (rnd < 1024)
rnd = (uint16_t)rand();
OFSocketAddressSetIPPort(address, rnd);
if ((ret = bind(_socket,
(struct sockaddr *)&address->sockaddr,
address->length)) == 0)
break;
if (OFSocketErrNo() != EADDRINUSE) {
|
| ︙ | ︙ |