Browse Source

Fix multiple config item removal. Thanks to zyxwvu Shi <i@shiyc.cn>

Serj Kalichev 3 years ago
parent
commit
090989200b
1 changed files with 1 additions and 1 deletions
  1. 1 1
      konf/tree/tree.c

+ 1 - 1
konf/tree/tree.c

@@ -276,9 +276,9 @@ int konf_tree_del_pattern(konf_tree_t *this,
 			res++;
 			continue;
 		}
+		lub_list_node_copy(tmp, iter);
 		lub_list_del(this->list, iter);
 		konf_tree_delete(conf);
-		lub_list_node_copy(tmp, iter);
 		lub_list_node_free(iter);
 		iter = tmp;
 		del_cnt++;