Commit 086771ab by Aaron Leung

Making sure to free the error message string if it gets allocated.

parent 1df5371c
......@@ -17,8 +17,9 @@ extern "C" {
void sass_free_context(sass_context* ctx)
{
if (ctx->output_string)
free(ctx->output_string);
if (ctx->output_string) free(ctx->output_string);
if (ctx->error_message) free(ctx->error_message);
free(ctx);
}
......@@ -27,8 +28,9 @@ extern "C" {
void sass_free_file_context(sass_file_context* ctx)
{
if (ctx->output_string)
free(ctx->output_string);
if (ctx->output_string) free(ctx->output_string);
if (ctx->error_message) free(ctx->error_message);
free(ctx);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment