Index: res/res_http_post.c =================================================================== --- res/res_http_post.c (revision 135437) +++ res/res_http_post.c (working copy) @@ -289,11 +289,14 @@ struct ast_str *ds; if (!(urih = ast_calloc(sizeof(*urih), 1))) { + ast_config_destroy(cfg); return -1; } - if (!(ds = ast_str_create(32))) + if (!(ds = ast_str_create(32))) { + ast_config_destroy(cfg); return -1; + } urih->description = ast_strdup("HTTP POST mapping");