annotate asfcrypt.h @ 4037:5f65cbe25494 libavformat

Fix memleak caused by the fact that url_open_buf() allocates a context when calling, but url_close_buf() doesn't free it. The better solution is to not allocate it at all, init it with init_put_byte() and then not have to close it at all. In the case where we do need to hold it around for longer than within the function context, we allocate it with av_alloc_put_byte() and free it with av_free() instead. Discussed in ML thread "[PATCH] fix small memleak in rdt.c".
author rbultje
date Mon, 17 Nov 2008 14:23:20 +0000
parents 1b6245500d8c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2652
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
1 /*
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
2 * ASF decryption
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
3 * Copyright (c) 2007 Reimar Doeffinger
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
4 *
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
5 * This file is part of FFmpeg.
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
6 *
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
7 * FFmpeg is free software; you can redistribute it and/or
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
8 * modify it under the terms of the GNU Lesser General Public
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
9 * License as published by the Free Software Foundation; either
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
10 * version 2.1 of the License, or (at your option) any later version.
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
11 *
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
12 * FFmpeg is distributed in the hope that it will be useful,
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
15 * Lesser General Public License for more details.
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
16 *
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
17 * You should have received a copy of the GNU Lesser General Public
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
18 * License along with FFmpeg; if not, write to the Free Software
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
20 */
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
21
3852
1b6245500d8c Globally rename the header inclusion guard names.
stefano
parents: 2779
diff changeset
22 #ifndef AVFORMAT_ASFCRYPT_H
1b6245500d8c Globally rename the header inclusion guard names.
stefano
parents: 2779
diff changeset
23 #define AVFORMAT_ASFCRYPT_H
2652
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
24
2779
149800f1778e Add missing #includes to fix 'make checkheaders'.
diego
parents: 2656
diff changeset
25 #include <inttypes.h>
149800f1778e Add missing #includes to fix 'make checkheaders'.
diego
parents: 2656
diff changeset
26
2652
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
27 void ff_asfcrypt_dec(const uint8_t key[20], uint8_t *data, int len);
2d28b2a5b2e4 Add support for decrypting asf files
reimar
parents:
diff changeset
28
3852
1b6245500d8c Globally rename the header inclusion guard names.
stefano
parents: 2779
diff changeset
29 #endif /* AVFORMAT_ASFCRYPT_H */