diff options
author | Ganesh Ajjanagadde <gajjanagadde@gmail.com> | 2015-10-05 01:45:12 -0400 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2015-10-05 19:30:20 +0200 |
commit | 1d4af04adf99301e21d7364d72f5570f5219083a (patch) | |
tree | b9a530f93e8319bb754096b7e1a3be61e1f9b308 /libavcodec/atrac3plus_data.h | |
parent | 6f1ccca4ae3b93b6a2a820a7a0e72081ab35767c (diff) | |
download | ffmpeg-1d4af04adf99301e21d7364d72f5570f5219083a.tar.gz |
avutil/attributes: add av_warn_unused_result
GCC 3.4 introduced an attribute warn_unused_result to warn when a programmer
discards the return value. Applying this judiciously across the codebase can help
in fixing a lot of problems. At a high level, functions which return error codes
should always be checked. More concretely, consider the functions ff_add_format
and the like in avfilter/formats.h. A quick examination shows that a large portion
of libavfilter fails to handle the associated errors, usually AVERROR(ENOMEM).
The above example was where I observed the utility of this, but it should be
useful in many places across the code base.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/atrac3plus_data.h')
0 files changed, 0 insertions, 0 deletions