Mercurial > mplayer.hg
changeset 12083:9aabf1beeb4f
remote exploitable heap overflow fix by ("blexim" <blexim at hush dot com>)
author | michael |
---|---|
date | Tue, 30 Mar 2004 10:58:41 +0000 |
parents | f705b0777572 |
children | 68baf8877c07 |
files | libmpdemux/http.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/libmpdemux/http.c Tue Mar 30 01:05:51 2004 +0000 +++ b/libmpdemux/http.c Tue Mar 30 10:58:41 2004 +0000 @@ -175,7 +175,7 @@ if( http_hdr->method==NULL ) http_set_method( http_hdr, "GET"); if( http_hdr->uri==NULL ) http_set_uri( http_hdr, "/"); else { - uri = (char*)malloc(strlen(http_hdr->uri)*2); + uri = (char*)malloc((strlen(http_hdr->uri)*3) + 1); if( uri==NULL ) { mp_msg(MSGT_NETWORK,MSGL_ERR,"Memory allocation failed\n"); return NULL;