diff options
author | Sebastian Hahn <sebastian@torproject.org> | 2011-08-16 01:38:15 +0200 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2011-08-17 10:41:36 -0400 |
commit | 6a06f45b04b8c9336ff150d299732c67bb5cb885 (patch) | |
tree | ca1581381ab31c05d7250d557bb104219ef00288 /src/common/torint.h | |
parent | 2dc40b9c49ec13ed24b5a541ce6cfecfe79effbf (diff) | |
download | tor-6a06f45b04b8c9336ff150d299732c67bb5cb885.tar.gz tor-6a06f45b04b8c9336ff150d299732c67bb5cb885.zip |
Actually pick a random port when "auto" is specified
ddc65e2b3303559ab7b842a176ee6c2eda9e4027 had broken this
Diffstat (limited to 'src/common/torint.h')
-rw-r--r-- | src/common/torint.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/common/torint.h b/src/common/torint.h index 0b5c29adc0..af975471f1 100644 --- a/src/common/torint.h +++ b/src/common/torint.h @@ -111,6 +111,15 @@ typedef signed int int32_t; typedef unsigned int uint32_t; #define HAVE_UINT32_T #endif +#ifndef UINT16_MAX +#define UINT16_MAX 0xffffu +#endif +#ifndef INT16_MAX +#define INT16_MAX 0x7fff +#endif +#ifndef INT16_MIN +#define INT16_MIN (-INT16_MAX-1) +#endif #ifndef UINT32_MAX #define UINT32_MAX 0xffffffffu #endif |