diff --git a/subprojects/gstreamer/plugins/elements/gstfilesink.c b/subprojects/gstreamer/plugins/elements/gstfilesink.c index 8802c6d171..d5808fd97f 100644 --- a/subprojects/gstreamer/plugins/elements/gstfilesink.c +++ b/subprojects/gstreamer/plugins/elements/gstfilesink.c @@ -153,6 +153,9 @@ gst_fopen (const gchar * filename, const gchar * mode, gboolean o_sync) fd = open (filename, flags, 0666); + if (fd < 0) + return NULL; + retval = fdopen (fd, mode); return retval; #endif