Skip to content
Snippets Groups Projects
Commit 211b9e55 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

curl_unescape() could make a buffer overflow

parent bc5c4b89
No related branches found
No related tags found
No related merge requests found
......@@ -47,7 +47,7 @@
char *curl_escape(char *string)
{
int alloc=strlen(string);
int alloc=strlen(string)+1;
char *ns = malloc(alloc);
unsigned char in;
int newlen = alloc;
......@@ -83,7 +83,7 @@ char *curl_escape(char *string)
char *curl_unescape(char *string)
{
int alloc = strlen(string);
int alloc = strlen(string)+1;
char *ns = malloc(alloc);
unsigned char in;
int index=0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment