hare

[hare] The Hare programming language
git clone https://git.torresjrjr.com/hare.git
Log | Files | Refs | README | LICENSE

commit f86268c19270790d619b9c9f033d2ea2affaa083
parent 3b095c26ab8f8437e9013b08de27535b8e9ea9da
Author: Sebastian <sebastian@sebsite.pw>
Date:   Mon, 27 Nov 2023 01:18:56 -0500

cmd/hare: fix memory leaks

Signed-off-by: Sebastian <sebastian@sebsite.pw>

Diffstat:
Mcmd/hare/deps.ha | 2+-
Mcmd/haredoc/main.ha | 2+-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/cmd/hare/deps.ha b/cmd/hare/deps.ha @@ -26,7 +26,7 @@ type link = struct { fn deps(name: str, cmd: *getopt::command) (void | error) = { let tags = default_tags()?; - defer free(tags); + defer strings::freeall(tags); let build_dir: str = ""; let goal = deps_fmt::TERM; diff --git a/cmd/haredoc/main.ha b/cmd/haredoc/main.ha @@ -59,7 +59,7 @@ fn doc(name: str, cmd: *getopt::command) (void | error) = { let template = true; let show_undocumented = false; let tags: []str = default_tags()?; - defer free(tags); + defer strings::freeall(tags); for (let i = 0z; i < len(cmd.opts); i += 1) { let opt = cmd.opts[i];