瀏覽代碼

fix an assert on startup when the disk is full and you're logging to a file

svn:r3204
Roger Dingledine 20 年之前
父節點
當前提交
c3189c2573
共有 1 個文件被更改,包括 1 次插入3 次删除
  1. 1 3
      src/common/log.c

+ 1 - 3
src/common/log.c

@@ -393,9 +393,7 @@ int add_file_log(int loglevelMin, int loglevelMax, const char *filename)
   add_stream_log(loglevelMin, loglevelMax, filename, f);
   logfiles->needs_close = 1;
   if (log_tor_version(logfiles, 0) < 0) {
-    logfile_t *victim = logfiles;
-    logfiles = victim->next;
-    delete_log(victim);
+    delete_log(logfiles);
   }
   return 0;
 }