Browse Source

avpacket: use ERANGE instead of EOVERFLOW

EOVERFLOW seems to be unavailable on certain platforms.
tags/n3.0
Anton Khirnov 9 years ago
parent
commit
68e547ae8b
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavcodec/avpacket.c

+ 1
- 1
libavcodec/avpacket.c View File

@@ -243,7 +243,7 @@ int av_packet_add_side_data(AVPacket *pkt, enum AVPacketSideDataType type,
int elems = pkt->side_data_elems;

if ((unsigned)elems + 1 > INT_MAX / sizeof(*pkt->side_data))
return AVERROR(EOVERFLOW);
return AVERROR(ERANGE);

pkt->side_data = av_realloc(pkt->side_data,
(elems + 1) * sizeof(*pkt->side_data));


Loading…
Cancel
Save