Commit cb64b2a5 authored by Wim Taymans's avatar Wim Taymans

gst/elements/gstfilesink.c: Don't use NULL pointers.

Original commit message from CVS:
* gst/elements/gstfilesink.c: (gst_file_sink_close_file):
Don't use NULL pointers.
parent 93c6b880
2005-10-06 Wim Taymans <wim@fluendo.com>
* gst/elements/gstfilesink.c: (gst_file_sink_close_file):
Don't use NULL pointers.
2005-10-06 Thomas Vander Stichele <thomas at apestaart dot org>
* gst/gst_private.h:
......
......@@ -261,9 +261,11 @@ gst_file_sink_open_file (GstFileSink * sink)
static void
gst_file_sink_close_file (GstFileSink * sink)
{
if (fclose (sink->file) != 0) {
GST_ELEMENT_ERROR (sink, RESOURCE, CLOSE,
(_("Error closing file \"%s\"."), sink->filename), GST_ERROR_SYSTEM);
if (sink->file) {
if (fclose (sink->file) != 0) {
GST_ELEMENT_ERROR (sink, RESOURCE, CLOSE,
(_("Error closing file \"%s\"."), sink->filename), GST_ERROR_SYSTEM);
}
}
}
......
......@@ -261,9 +261,11 @@ gst_file_sink_open_file (GstFileSink * sink)
static void
gst_file_sink_close_file (GstFileSink * sink)
{
if (fclose (sink->file) != 0) {
GST_ELEMENT_ERROR (sink, RESOURCE, CLOSE,
(_("Error closing file \"%s\"."), sink->filename), GST_ERROR_SYSTEM);
if (sink->file) {
if (fclose (sink->file) != 0) {
GST_ELEMENT_ERROR (sink, RESOURCE, CLOSE,
(_("Error closing file \"%s\"."), sink->filename), GST_ERROR_SYSTEM);
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment