Fix little bug: ensure number of children is incremented when adding a

new node to a dir.
This commit is contained in:
Vreixo Formoso 2007-12-06 02:38:19 +01:00
parent d4deb4866f
commit 007be29c6d

View File

@ -90,7 +90,7 @@ int iso_tree_add_new_dir(IsoDir *parent, const char *name, IsoDir **dir)
if (dir) {
*dir = node;
}
return ISO_SUCCESS;
return ++parent->nchildren;
}
/**
@ -178,5 +178,5 @@ int iso_tree_add_new_symlink(IsoDir *parent, const char *name,
if (link) {
*link = node;
}
return ISO_SUCCESS;
return ++parent->nchildren;
}