summaryrefslogtreecommitdiff
path: root/src/context.c
diff options
context:
space:
mode:
authorDaniel Stone <daniel@fooishbar.org>2012-03-29 01:41:40 +0100
committerDaniel Stone <daniel@fooishbar.org>2012-03-29 01:41:40 +0100
commitaa9f2bf98ddc4d38408596159512c46f0e331409 (patch)
tree20027f56452acb6343480ebb7119e29c390b3eca /src/context.c
parent6628cf0bed4b323d07b430bfe84daacc11a547a6 (diff)
Don't leak include_paths in context
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Diffstat (limited to 'src/context.c')
-rw-r--r--src/context.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/context.c b/src/context.c
index 0c5da91..fbb93e4 100644
--- a/src/context.c
+++ b/src/context.c
@@ -101,6 +101,7 @@ xkb_context_include_path_append_default(struct xkb_context *context)
if (err <= 0)
return 1;
(void) xkb_context_include_path_append(context, user_path);
+ free(user_path);
return 1;
}
@@ -117,6 +118,8 @@ xkb_context_include_path_clear(struct xkb_context *context)
free(context->include_paths[i]);
context->include_paths[i] = NULL;
}
+ free(context->include_paths);
+ context->include_paths = NULL;
context->num_include_paths = 0;
}