If a file is deleted, the leftmost child in the RB tree has it's sub directories wiped out.
The following test shows this bug:
[TestMethod]
public void CompoundFile_Delete_ChildElementMaintainsFiles()
{
using (var compoundFile = new CompoundFile())
{
var storage1 = compoundFile.RootStorage.AddStorage("1");
var storage2 = compoundFile.RootStorage.AddStorage("2");
var storage3 = compoundFile.RootStorage.AddStorage("3");
storage1.AddStream("1.1");
compoundFile.RootStorage.Delete("2");
storage1 = compoundFile.RootStorage.GetStorage("1");
storage1.GetStream("1.1");
}
}