~sircmpwn/hare-xml

f4ec931b910928f3037bacdc71f99a3ab3a7ee97 — Sebastian 7 months ago c86eac3
xml: fix memory leak

Signed-off-by: Sebastian <sebastian@sebsite.pw>
1 files changed, 6 insertions(+), 1 deletions(-)

M parser.ha
M parser.ha => parser.ha +6 -1
@@ 35,7 35,12 @@ export fn parse(in: io::handle) (*parser | error) = {
		par.in = alloc(bufio::buffered(in, par.buf[..], []));
		par.close = true;
	};
	prolog(par)?;
	match (prolog(par)) {
	case void => void;
	case let err: error =>
		parser_free(par);
		return err;
	};
	return par;
};