diff options
author | Nick Mathewson <nickm@torproject.org> | 2016-06-11 10:15:40 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2016-06-11 10:15:40 -0400 |
commit | d6b2af7a3aba24cf3d77587c41028aad70d59605 (patch) | |
tree | a6d8687d4055a9e27fbcb406cfb518295469bf0c /src/or/config.c | |
parent | c274f825da18f33f12eb78260d1c78d5f685d959 (diff) | |
parent | e80a032b61e3c793ad0d1627074b8750f7cfec48 (diff) | |
download | tor-d6b2af7a3aba24cf3d77587c41028aad70d59605.tar.gz tor-d6b2af7a3aba24cf3d77587c41028aad70d59605.zip |
Merge branch 'bug19180_easy_squashed'
Diffstat (limited to 'src/or/config.c')
-rw-r--r-- | src/or/config.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/or/config.c b/src/or/config.c index b9e8700b4f..8a3fb47790 100644 --- a/src/or/config.c +++ b/src/or/config.c @@ -65,9 +65,6 @@ #include <systemd/sd-daemon.h> #endif -/* From main.c */ -extern int quiet_level; - /* Prefix used to indicate a Unix socket in a FooPort configuration. */ static const char unix_socket_prefix[] = "unix:"; @@ -2677,7 +2674,7 @@ options_validate_cb(void *old_options, void *options, void *default_options, #define REJECT(arg) \ STMT_BEGIN *msg = tor_strdup(arg); return -1; STMT_END -#ifdef __GNUC__ +#if defined(__GNUC__) && __GNUC__ <= 3 #define COMPLAIN(args...) \ STMT_BEGIN log_warn(LD_CONFIG, args); STMT_END #else @@ -5776,7 +5773,7 @@ parse_dir_authority_line(const char *line, dirinfo_type_t required_type, } else if (!strcmpstart(flag, "weight=")) { int ok; const char *wstring = flag + strlen("weight="); - weight = tor_parse_double(wstring, 0, UINT64_MAX, &ok, NULL); + weight = tor_parse_double(wstring, 0, (double)UINT64_MAX, &ok, NULL); if (!ok) { log_warn(LD_CONFIG, "Invalid weight '%s' on DirAuthority line.",flag); weight=1.0; @@ -5920,7 +5917,7 @@ parse_dir_fallback_line(const char *line, } else if (!strcmpstart(cp, "weight=")) { int ok; const char *wstring = cp + strlen("weight="); - weight = tor_parse_double(wstring, 0, UINT64_MAX, &ok, NULL); + weight = tor_parse_double(wstring, 0, (double)UINT64_MAX, &ok, NULL); if (!ok) { log_warn(LD_CONFIG, "Invalid weight '%s' on FallbackDir line.", cp); weight=1.0; |