Skip to content

Commit deb38d5

Browse files
authored
Merge pull request #977 from mruprich/master
log BUGFIX LOGBUF should be called before free
2 parents a34e230 + 63c95c1 commit deb38d5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/parser.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1076,8 +1076,8 @@ make_canonical(struct ly_ctx *ctx, int type, const char **value, void *data1, vo
10761076
count += exp->tok_len[i] - j;
10771077
} else {
10781078
if (count + exp->tok_len[i] > buf_len) {
1079-
lyxp_expr_free(exp);
10801079
LOGBUF(&exp->expr[exp->expr_pos[i]]);
1080+
lyxp_expr_free(exp);
10811081
return -1;
10821082
}
10831083
strncpy(&buf[count], &exp->expr[exp->expr_pos[i]], exp->tok_len[i]);

0 commit comments

Comments
 (0)