diff options
Diffstat (limited to 'bsd-bindresvport.c')
-rw-r--r-- | bsd-bindresvport.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/bsd-bindresvport.c b/bsd-bindresvport.c index 536a5056f..7faf73191 100644 --- a/bsd-bindresvport.c +++ b/bsd-bindresvport.c | |||
@@ -88,6 +88,9 @@ bindresvport_af(sd, sa, af) | |||
88 | if (port == 0) | 88 | if (port == 0) |
89 | port = (arc4random() % NPORTS) + STARTPORT; | 89 | port = (arc4random() % NPORTS) + STARTPORT; |
90 | 90 | ||
91 | /* Avoid warning */ | ||
92 | error = -1; | ||
93 | |||
91 | for(i = 0; i < NPORTS; i++) { | 94 | for(i = 0; i < NPORTS; i++) { |
92 | *portp = htons(port); | 95 | *portp = htons(port); |
93 | 96 | ||