]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
make our tor_assert actually work when it's going to be triggered,
authorRoger Dingledine <arma@torproject.org>
Thu, 23 Sep 2004 05:02:51 +0000 (05:02 +0000)
committerRoger Dingledine <arma@torproject.org>
Thu, 23 Sep 2004 05:02:51 +0000 (05:02 +0000)
rather than seg fault

svn:r2368

src/common/log.c

index bdbb488ade6346925f7aa35339d0fd8a0b11006d..1a91d072ab5700ec20c8fcb5b93e35d6b3183078 100644 (file)
@@ -233,7 +233,7 @@ static void delete_log(logfile_t *victim) {
     logfiles = victim->next;
   else {
     for(tmpl = logfiles; tmpl && tmpl->next != victim; tmpl=tmpl->next) ;
-    tor_assert(tmpl->next == victim);
+    tor_assert(tmpl && tmpl->next == victim);
     tmpl->next = victim->next;
   }
   tor_free(victim->filename);