diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-09-28 13:36:22 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-09-28 13:54:40 +0200 |
commit | 2acb5cd90793de7f375bf6ebf4eabe2b59a2ecc3 (patch) | |
tree | 5d827d355bab646ca6ccdebe930ac927a02c3713 /libavformat | |
parent | 4fefe91a33956007f17cfd6e0c5ee1cb3a3f36d8 (diff) | |
parent | d16860a237ae56a21d051df6556c40de9be53faa (diff) | |
download | ffmpeg-2acb5cd90793de7f375bf6ebf4eabe2b59a2ecc3.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
libopus: Remap channels using libopus' internal remapping.
Opus decoder using libopus
avcodec: document the use of AVCodecContext.delay for audio decoding
vc1dec: add flush function for WMV9 and VC-1 decoders
http: Increase buffer sizes to cope with longer URIs
nutenc: const correctness for ff_put_v_trace/put_s_trace function arguments
h264_refs: Fix debug tprintf argument types
golomb: const correctness for get_ue()/get_se() function arguments
get_bits: const correctness for get_bits_trace()/get_xbits_trace() arguments
Conflicts:
Changelog
libavcodec/Makefile
libavcodec/version.h
libavformat/http.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/http.c | 13 | ||||
-rw-r--r-- | libavformat/nutenc.c | 8 |
2 files changed, 14 insertions, 7 deletions
diff --git a/libavformat/http.c b/libavformat/http.c index ede4e8b6f6..6412265310 100644 --- a/libavformat/http.c +++ b/libavformat/http.c @@ -32,8 +32,11 @@ /* XXX: POST protocol is not completely implemented because ffmpeg uses only a subset of it. */ -/* used for protocol handling */ -#define BUFFER_SIZE 4096 +/* The IO buffer size is unrelated to the max URL size in itself, but needs + * to be large enough to fit the full request headers (including long + * path names). + */ +#define BUFFER_SIZE MAX_URL_SIZE #define MAX_REDIRECTS 8 typedef struct { @@ -101,8 +104,8 @@ static int http_open_cnx(URLContext *h) const char *path, *proxy_path, *lower_proto = "tcp", *local_path; char hostname[1024], hoststr[1024], proto[10]; char auth[1024], proxyauth[1024] = ""; - char path1[1024]; - char buf[1024], urlbuf[1024]; + char path1[MAX_URL_SIZE]; + char buf[1024], urlbuf[MAX_URL_SIZE]; int port, use_proxy, err, location_changed = 0, redirects = 0, attempts = 0; HTTPAuthType cur_auth_type, cur_proxy_auth_type; HTTPContext *s = h->priv_data; @@ -352,7 +355,7 @@ static inline int has_header(const char *str, const char *header) static int http_read_header(URLContext *h, int *new_location) { HTTPContext *s = h->priv_data; - char line[1024]; + char line[MAX_URL_SIZE]; int err = 0; s->chunksize = -1; diff --git a/libavformat/nutenc.c b/libavformat/nutenc.c index d227c9a314..d3db102589 100644 --- a/libavformat/nutenc.c +++ b/libavformat/nutenc.c @@ -266,13 +266,17 @@ static void put_s(AVIOContext *bc, int64_t val){ } #ifdef TRACE -static inline void ff_put_v_trace(AVIOContext *bc, uint64_t v, char *file, char *func, int line){ +static inline void ff_put_v_trace(AVIOContext *bc, uint64_t v, const char *file, + const char *func, int line) +{ av_log(NULL, AV_LOG_DEBUG, "ff_put_v %5"PRId64" / %"PRIX64" in %s %s:%d\n", v, v, file, func, line); ff_put_v(bc, v); } -static inline void put_s_trace(AVIOContext *bc, int64_t v, char *file, char *func, int line){ +static inline void put_s_trace(AVIOContext *bc, int64_t v, const char *file, + const char *func, int line) +{ av_log(NULL, AV_LOG_DEBUG, "put_s %5"PRId64" / %"PRIX64" in %s %s:%d\n", v, v, file, func, line); put_s(bc, v); |