diff mbox series

[FFmpeg-devel,3/5] avcodec/packet: Improve documentation of av_packet_get_side_data

Message ID 20200621085349.22370-3-andreas.rheinhardt@gmail.com
State Accepted
Commit 45ddf06f54915bfcfb6bdfa8b983f4fdbf7bf4dc
Headers show
Series [FFmpeg-devel,1/5] avcodec/nellymoserdec: Don't use invalid AVPacketSideDataType | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Andreas Rheinhardt June 21, 2020, 8:53 a.m. UTC
Document that it also sets the size in case the desired side data is
absent (if the pointer has been supplied).

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
Do this and the next patch actually need a version bump and API change
entry?

 libavcodec/packet.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Anton Khirnov June 22, 2020, 8:53 a.m. UTC | #1
Quoting Andreas Rheinhardt (2020-06-21 10:53:47)
> Document that it also sets the size in case the desired side data is
> absent (if the pointer has been supplied).
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
> ---
> Do this and the next patch actually need a version bump and API change
> entry?

I'd say documenting existing behaviour is not an API change, so doesn't
need anything.
diff mbox series

Patch

diff --git a/libavcodec/packet.h b/libavcodec/packet.h
index 41485f4527..96f237f091 100644
--- a/libavcodec/packet.h
+++ b/libavcodec/packet.h
@@ -580,7 +580,8 @@  int av_packet_shrink_side_data(AVPacket *pkt, enum AVPacketSideDataType type,
  *
  * @param pkt packet
  * @param type desired side information type
- * @param size pointer for side information size to store (optional)
+ * @param size If supplied, *size will be set to the size of the side data
+ *             or to zero if the desired side data is not present.
  * @return pointer to data if present or NULL otherwise
  */
 uint8_t* av_packet_get_side_data(const AVPacket *pkt, enum AVPacketSideDataType type,