summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTing-Wei Lan <lantw44@gmail.com>2013-09-12 01:13:01 +0800
committerLAN-TW <lantw44@gmail.com>2013-09-12 01:13:44 +0800
commite131748ff7a62f6e82b7402452450019642538ec (patch)
treee1bd13124ad224458b7643f4211eb06eca8934b0
parentb77ba2c6f48a890a6c4f6d728791a2cdc85c5c4a (diff)
downloadgsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.tar
gsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.tar.gz
gsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.tar.bz2
gsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.tar.lz
gsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.tar.xz
gsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.tar.zst
gsoc2013-libgnome-autoar-e131748ff7a62f6e82b7402452450019642538ec.zip
Prevent calling g_output_stream_write with NULL stream
-rw-r--r--gnome-autoar/autoar-create.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gnome-autoar/autoar-create.c b/gnome-autoar/autoar-create.c
index 4b35b09..f5a16a8 100644
--- a/gnome-autoar/autoar-create.c
+++ b/gnome-autoar/autoar-create.c
@@ -473,7 +473,7 @@ libarchive_write_write_cb (struct archive *ar_write,
g_debug ("libarchive_write_write_cb: called");
arcreate = (AutoarCreate*)client_data;
- if (arcreate->priv->error != NULL) {
+ if (arcreate->priv->error != NULL || arcreate->priv->ostream == NULL) {
return -1;
}