]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Fix crash in first-time option validation. Oops.
authorNick Mathewson <nickm@torproject.org>
Thu, 10 Aug 2006 19:56:10 +0000 (19:56 +0000)
committerNick Mathewson <nickm@torproject.org>
Thu, 10 Aug 2006 19:56:10 +0000 (19:56 +0000)
svn:r7018

src/or/config.c

index 7f4525879c58007fa4289a881c389046a047c777..560428f4d79b2e30a562209c6b17538ebe44aa79 100644 (file)
@@ -2075,10 +2075,10 @@ options_validate(or_options_t *old_options, or_options_t *options,
     const char *tp = is_socks ? "SOCKS proxy" : "transparent proxy";
     if (is_socks) {
       opt = options->SocksListenAddress;
-      old = old_options->SocksListenAddress;
+      old = old_options ? old_options->SocksListenAddress : NULL;
     } else {
       opt = options->TransListenAddress;
-      old = old_options->TransListenAddress;
+      old = old_options ? old_options->TransListenAddress : NULL;
     }
 
     for (line = opt; line; line = line->next) {