diff options
author | David Schleef <ds@schleef.org> | 2004-03-06 01:25:58 +0000 |
---|---|---|
committer | David Schleef <ds@schleef.org> | 2004-03-06 01:25:58 +0000 |
commit | 16860a5c42ce4a0346768a2a2a742d35d263574b (patch) | |
tree | 6d8e73e50f20590df1984cf724af610647561d37 /tests | |
parent | 84dfbc108d8c14227dd2a5575cf80fe740120a8f (diff) |
gst/mpegstream/gstrfc2250enc.c: Fix code that ignores return value of gst_buffer_merge(). (bug #114560)
Original commit message from CVS:
* gst/mpegstream/gstrfc2250enc.c: (gst_rfc2250_enc_add_slice):
Fix code that ignores return value of gst_buffer_merge().
(bug #114560)
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_descramble_segment):
* gst/mpegstream/gstrfc2250enc.c: (gst_rfc2250_enc_add_slice): same
* testsuite/gst-lint: Check for above.
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/old/testsuite/gst-lint | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/tests/old/testsuite/gst-lint b/tests/old/testsuite/gst-lint index 98a338485..710ce9bbb 100755 --- a/tests/old/testsuite/gst-lint +++ b/tests/old/testsuite/gst-lint @@ -31,7 +31,7 @@ sub check_carriage_returns(); sub check_printf_lld(); sub check_glibisms(); sub check_indentation(); -sub check_gst_props_set(); +sub check_no_ignore(); sub check_deprecated(); sub check_config_h(); sub check_varargs_functions(); @@ -63,7 +63,7 @@ foreach $filename (<FIND>) { # important stuff check_bad_includes(); check_printf_lld(); - check_gst_props_set(); + check_no_ignore(); check_deprecated(); check_config_h(); check_old_typefind(); @@ -263,13 +263,18 @@ sub check_indentation() # -# gst_props_set() returns a value that should never be ignored -# may have false positives +# Check (roughly) for functions whose value should not be ignored # -sub check_gst_props_set() +sub check_no_ignore() { - if (grep { /^\s+gst_props_set\s*\(/; } @lines) { - print "E: return value of gst_props_set() possibly ignored\n"; + if (grep { /^\s+gst_buffer_merge\s*\(/; } @lines) { + print "E: return value of gst_buffer_merge () possibly ignored\n"; + } + if (grep { /^\s+malloc\s*\(/; } @lines) { + print "E: return value of malloc() possibly ignored\n"; + } + if (grep { /^\s+gst_buffer_new\s*\(/; } @lines) { + print "E: return value of gst_buffer_new() possibly ignored\n"; } } |