OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3c3b800
)
rtmppkt: Make pkt->data reallocable
author
Martin Storsjö
<martin@martin.st>
Mon, 24 Nov 2014 08:41:34 +0000
(10:41 +0200)
committer
Martin Storsjö
<martin@martin.st>
Fri, 28 Nov 2014 07:59:28 +0000
(09:59 +0200)
We try to avoid mixing av_malloc with av_realloc, since av_malloc
may be implemented with functions that can't (formally) be mixed
with the functions used in av_realloc.
Signed-off-by: Martin Storsjö <martin@martin.st>
libavformat/rtmppkt.c
patch
|
blob
|
history
diff --git
a/libavformat/rtmppkt.c
b/libavformat/rtmppkt.c
index
37fbb5f
..
e952091
100644
(file)
--- a/
libavformat/rtmppkt.c
+++ b/
libavformat/rtmppkt.c
@@
-395,7
+395,7
@@
int ff_rtmp_packet_create(RTMPPacket *pkt, int channel_id, RTMPPacketType type,
int timestamp, int size)
{
if (size) {
- pkt->data = av_
malloc(
size);
+ pkt->data = av_
realloc(NULL,
size);
if (!pkt->data)
return AVERROR(ENOMEM);
}