# # patch "roster.cc" # from [e89bd4067b9c09b13d887c04d08e9243f5f23c01] # to [94330facdd791b032a55fed00f98f4f26191a9cc] # ======================================================================== --- roster.cc e89bd4067b9c09b13d887c04d08e9243f5f23c01 +++ roster.cc 94330facdd791b032a55fed00f98f4f26191a9cc @@ -637,6 +637,10 @@ node_t n = get_node(nid); I(null_node(n->parent)); I(null_name(n->name)); + // if it's a dir, make sure it's empty + if (is_dir_t(n)) + I(downcast_to_dir_t(n)->children.empty()); + // all right, kill it safe_erase(nodes, nid); // can use safe_erase here, because while not every detached node appears in // old_locations, all those that used to be in the tree do. and you should