]> wimlib.net Git - wimlib/blobdiff - src/write.c
main_writer_thread_proc(): Re-instate removed condition
[wimlib] / src / write.c
index 3afa49872b40ef13308a4e79838e1063d7c3225f..a23aa450d211c63e27227fd170f6e8b1b3713367 100644 (file)
@@ -6,7 +6,6 @@
  */
 
 /*
- * Copyright (C) 2010 Carl Thijssen
  * Copyright (C) 2012 Eric Biggers
  *
  * This file is part of wimlib, a library for working with WIM files.
@@ -35,7 +34,7 @@
 
 #include "list.h"
 #include "wimlib_internal.h"
-#include "io.h"
+#include "buffer_io.h"
 #include "dentry.h"
 #include "lookup_table.h"
 #include "xml.h"
@@ -1021,6 +1020,7 @@ static int main_writer_thread_proc(struct list_head *stream_list,
                //
                // Otherwise, write all the chunks we can.
                while (cur_lte != NULL &&
+                      !list_empty(&cur_lte->msg_list) &&
                       (msg = container_of(cur_lte->msg_list.next,
                                           struct message,
                                           list))->complete)