aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorArvid Norberg <arvid@cs.umu.se>2014-02-14 08:20:59 +0100
committerDaniel Stenberg <daniel@haxx.se>2014-02-14 08:21:41 +0100
commit1813a77b024d03b59fe5b591a5c5ecced02a9e66 (patch)
tree298127f5b9e0e18b7c924278c7e03945eba99ec1 /lib
parentd3d871cb4fe1512b689bb29cb49473cfcf91c684 (diff)
dict: fix memory leak in OOM exit path
Bug: https://github.com/bagder/curl/pull/90
Diffstat (limited to 'lib')
-rw-r--r--lib/dict.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/dict.c b/lib/dict.c
index f5c892197..86ddfb9e2 100644
--- a/lib/dict.c
+++ b/lib/dict.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2012, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -122,9 +122,8 @@ static char *unescape_word(struct SessionHandle *data, const char *inputbuff)
dictp[olen++] = byte;
}
dictp[olen]=0;
-
- free(newp);
}
+ free(newp);
return dictp;
}