diff --git a/libavformat/http.c b/libavformat/http.c index fdfbc69da1..91650be47a 100644 --- a/libavformat/http.c +++ b/libavformat/http.c @@ -194,7 +194,7 @@ static int http_open_cnx_internal(URLContext *h, AVDictionary **options) char *hashmark; char hostname[1024], hoststr[1024], proto[10]; char auth[1024], proxyauth[1024] = ""; - char path1[MAX_URL_SIZE], sanitized_path[MAX_URL_SIZE]; + char path1[MAX_URL_SIZE], sanitized_path[MAX_URL_SIZE + 1]; char buf[1024], urlbuf[MAX_URL_SIZE]; int port, use_proxy, err, location_changed = 0; HTTPContext *s = h->priv_data;