aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2017-03-05 22:08:48 +0100
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2017-03-05 22:08:54 +0100
commit0737394fce1ccb4057c81e8bf43dcc1d422674e0 (patch)
tree9880c7e86dee429c3dfd05e1148fc785ff89334c
parent89e95da1eae31fd20da5039f96ebb5d2c447040c (diff)
downloadblogc-0737394fce1ccb4057c81e8bf43dcc1d422674e0.tar.gz
blogc-0737394fce1ccb4057c81e8bf43dcc1d422674e0.tar.bz2
blogc-0737394fce1ccb4057c81e8bf43dcc1d422674e0.zip
make: fixed segfault when blogcfile not found
-rw-r--r--src/blogc-make/ctx.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/blogc-make/ctx.c b/src/blogc-make/ctx.c
index ff825e1..fc59457 100644
--- a/src/blogc-make/ctx.c
+++ b/src/blogc-make/ctx.c
@@ -290,6 +290,8 @@ bm_ctx_free_internal(bm_ctx_t *ctx)
void
bm_ctx_free(bm_ctx_t *ctx)
{
+ if (ctx == NULL)
+ return;
bm_ctx_free_internal(ctx);
free(ctx->blogc);
free(ctx->blogc_runserver);