summaryrefslogtreecommitdiff
path: root/libavformat/avio.c
diff options
context:
space:
mode:
authorMartin Storsjö <martin@martin.st>2013-10-29 22:52:09 +0200
committerMartin Storsjö <martin@martin.st>2013-10-30 09:53:48 +0200
commit0c5f839693da2276c2da23400f67a67be4ea0af1 (patch)
treeb264fc3c396e9c2fa51d358dfca86b40fd41e1f5 /libavformat/avio.c
parent4f2d8968c04ef76bb18df103a1287b864c0e6fe6 (diff)
lavf: Remove a now useless parameter to ffurl_register_protocol
This was added in 9b07a2dc02e9 as an ABI hack to allow older code built with lavf 52 to register protocols even if the size of the URLProtocol struct was increased. Later, registering protocols from outside of lavf was removed and this workaround isn't needed any longer since lavf 53. This removes an unchecked malloc and a memory leak for the cases when this workaround actually was used - which it hasn't since lavf 53. Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavformat/avio.c')
-rw-r--r--libavformat/avio.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/libavformat/avio.c b/libavformat/avio.c
index e07b23609d..fe42974d3a 100644
--- a/libavformat/avio.c
+++ b/libavformat/avio.c
@@ -94,14 +94,9 @@ const char *avio_enum_protocols(void **opaque, int output)
return avio_enum_protocols(opaque, output);
}
-int ffurl_register_protocol(URLProtocol *protocol, int size)
+int ffurl_register_protocol(URLProtocol *protocol)
{
URLProtocol **p;
- if (size < sizeof(URLProtocol)) {
- URLProtocol *temp = av_mallocz(sizeof(URLProtocol));
- memcpy(temp, protocol, size);
- protocol = temp;
- }
p = &first_protocol;
while (*p != NULL)
p = &(*p)->next;