Bug 39056

Summary: getStorageClsid() on the root node always returns zero.
Product: POI Reporter: Trejkaz (pen name) <trejkaz>
Component: POIFSAssignee: POI Developers List <dev>
Severity: normal Keywords: PatchAvailable
Priority: P2    
Version: 3.0-dev   
Target Milestone: ---   
Hardware: Other   
OS: other   
Attachments: Workaround for the bug
Patch against current trunk

Description Trejkaz (pen name) 2006-03-21 23:04:42 UTC
After creating a POIFSFileSystem, fs.getRoot().getStorageClsid() always returns
a GUID consisting entirely of zeros.
Comment 1 Trejkaz (pen name) 2006-03-21 23:05:29 UTC
Created attachment 17932 [details]
Workaround for the bug

The real problem is probably that the recursive processProperties() method only
processes the children and below.  That method *does* manually set in the class
ID for the directory nodes, it's only the root which doesn't get it set (which
is where it is almost always needed.)

I suppose a slightly better solution than my workaround would be having
processProperties() start from the root.  But the problem is, the
PropertyTable() constructor automatically adds the root node all by itself, so
it would need a setRoot() method perhaps.
Comment 2 David Fisher 2008-12-29 14:56:28 UTC
The code has been changed and will no longer support this workaround.

Please check with the latest 3.5beta4 and re-open if you still have trouble with the root CLSID.
Comment 3 Trejkaz (pen name) 2009-04-07 19:29:52 UTC
Created attachment 23457 [details]
Patch against current trunk

Still a problem, here's an updated patch.
Comment 4 Yegor Kozlov 2009-04-20 10:09:46 UTC
Applied in r766757