path UPDATE context not required for freeing
diff --git a/src/tree_data_new.c b/src/tree_data_new.c
index 792e019..7b26508 100644
--- a/src/tree_data_new.c
+++ b/src/tree_data_new.c
@@ -1823,7 +1823,7 @@
             LY_ARRAY_INCREMENT(p);
         }
     }
-    ly_path_free(ctx, p);
+    ly_path_free(p);
     if (!ret) {
         /* set out params only on success */
         if (new_parent) {