Making calls to opus_packet_pad() on a bad packet return OPUS_INVALID_PACKET
authorJean-Marc Valin <jmvalin@jmvalin.ca>
Mon, 4 Jul 2016 05:29:23 +0000 (01:29 -0400)
committerJean-Marc Valin <jmvalin@jmvalin.ca>
Mon, 4 Jul 2016 05:29:23 +0000 (01:29 -0400)
commit328953e1896432bc700b9b5c69ae2987c5d752f4
tree10f574c6f6e3c42644728f352747ce97d78171ea
parentf6f8487b76f234437e7d4c2831e630d9d06cb074
Making calls to opus_packet_pad() on a bad packet return OPUS_INVALID_PACKET

We were previously returning OPUS_BAD_ARG because the failure was
only detected in opus_repacketizer_out_range_impl() rather than in
opus_repacketizer_cat(). Checking the return value from opus_repacketizer_cat()
also addresses the last outstanding Coverity defect.
src/opus_multistream_encoder.c
src/repacketizer.c
tests/test_opus_api.c