fix uci rename for anonymous sections
[project/uci.git] / history.c
index 789cd87..a31dbfa 100644 (file)
--- a/history.c
+++ b/history.c
@@ -318,7 +318,7 @@ static void uci_filter_history(struct uci_context *ctx, const char *name, const
 done:
        if (filename)
                free(filename);
-       uci_close_stream(f);
+       uci_close_stream(pctx->file);
        uci_foreach_element_safe(&list, tmp, e) {
                uci_free_element(e);
        }