Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Unified Diff: source/patched-ffmpeg-mt/libavformat/rtpdec_mpeg4.c

Issue 3384002: ffmpeg source update for sep 09 (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/ffmpeg/
Patch Set: Created 10 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: source/patched-ffmpeg-mt/libavformat/rtpdec_mpeg4.c
===================================================================
--- source/patched-ffmpeg-mt/libavformat/rtpdec_mpeg4.c (revision 59334)
+++ source/patched-ffmpeg-mt/libavformat/rtpdec_mpeg4.c (working copy)
@@ -61,35 +61,6 @@
int cur_au_index;
};
-/* return the length and optionally the data */
-static int hex_to_data(uint8_t *data, const char *p)
-{
- int c, len, v;
-
- len = 0;
- v = 1;
- for (;;) {
- p += strspn(p, SPACE_CHARS);
- if (*p == '\0')
- break;
- c = toupper((unsigned char) *p++);
- if (c >= '0' && c <= '9')
- c = c - '0';
- else if (c >= 'A' && c <= 'F')
- c = c - 'A' + 10;
- else
- break;
- v = (v << 4) | c;
- if (v & 0x100) {
- if (data)
- data[len] = v;
- len++;
- v = 1;
- }
- }
- return len;
-}
-
typedef struct {
const char *str;
uint16_t type;
@@ -139,14 +110,14 @@
static int parse_fmtp_config(AVCodecContext * codec, char *value)
{
/* decode the hexa encoded parameter */
- int len = hex_to_data(NULL, value);
+ int len = ff_hex_to_data(NULL, value);
if (codec->extradata)
av_free(codec->extradata);
codec->extradata = av_mallocz(len + FF_INPUT_BUFFER_PADDING_SIZE);
if (!codec->extradata)
return AVERROR(ENOMEM);
codec->extradata_size = len;
- hex_to_data(codec->extradata, value);
+ ff_hex_to_data(codec->extradata, value);
return 0;
}
« no previous file with comments | « source/patched-ffmpeg-mt/libavformat/rtpdec_latm.c ('k') | source/patched-ffmpeg-mt/libavformat/rtpdec_vp8.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698