diff options
author | Tim-Philipp Müller <tim@centricular.net> | 2006-07-19 11:43:50 +0000 |
---|---|---|
committer | Tim-Philipp Müller <tim@centricular.net> | 2006-07-19 11:43:50 +0000 |
commit | 1e5dc348d495052779739a95c6ae7b70556fc7ad (patch) | |
tree | 5a85c2c5caaa8209689c2a10f0151abe48597c8b /gst | |
parent | d9f52eff8b966cfb4329babf61b6b2a9fc61c6e2 (diff) | |
download | gst-plugins-bad-1e5dc348d495052779739a95c6ae7b70556fc7ad.tar.gz gst-plugins-bad-1e5dc348d495052779739a95c6ae7b70556fc7ad.tar.bz2 gst-plugins-bad-1e5dc348d495052779739a95c6ae7b70556fc7ad.zip |
gst/nsf/nsf.c: Really fix compilation. Apparently it's not enough to just check the return value for errors, but we n...
Original commit message from CVS:
* gst/nsf/nsf.c: (nsf_load):
Really fix compilation. Apparently it's not enough to
just check the return value for errors, but we need to
check for short reads as well (now if only we handled
them too ...). Fixes #347935.
Diffstat (limited to 'gst')
-rw-r--r-- | gst/nsf/nsf.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gst/nsf/nsf.c b/gst/nsf/nsf.c index 048b4b12..aae9bc83 100644 --- a/gst/nsf/nsf.c +++ b/gst/nsf/nsf.c @@ -476,7 +476,7 @@ nsf_load (char *filename, void *source, int length) /* seek to end of header, read in data */ if (NULL == source) { fseek (fp, NSF_HEADER_SIZE, SEEK_SET); - if (fread (temp_nsf->data, temp_nsf->length, 1, fp) < 0) + if (fread (temp_nsf->data, temp_nsf->length, 1, fp) != 1) log_printf ("error reading end of header\n"); fclose (fp); @@ -585,6 +585,13 @@ nsf_setfilter (nsf_t * nsf, int filter_type) /* ** $Log$ +** Revision 1.3 2006/07/19 11:43:50 tpm +** * gst/nsf/nsf.c: (nsf_load): +** Really fix compilation. Apparently it's not enough to +** just check the return value for errors, but we need to +** check for short reads as well (now if only we handled +** them too ...). Fixes #347935. +** ** Revision 1.2 2006/07/18 09:36:46 wtay ** * gst/nsf/nsf.c: (nsf_load): ** Fix compilation by not ignoring return values of fread. |