Closed smlpt closed 6 months ago
@smlpt i see the code you are pointing at but did you confirm that generateUniqueName()
is actually repeatedly called? I did some quick checks with different node types that do call generateUniqueName
before going on to call addNode
. I didn't see multiple calls to generateUniqueName()
. However, I didnt verify with a bdv xml though because i dont have one readily accessible.
@kephale so when I add an info log to generateUniqueName
and add a box to the scene, it logs:
[INFO] generated unique name Box
[INFO] generated unique name Box
When I open an XML-based volume, it also logs:
[INFO] generated unique name C:\Software\datasets\MastodonTutorialDataset1\datasethdf5.xml
[INFO] generated unique name C:\Software\datasets\MastodonTutorialDataset1\datasethdf5.xml
And since most other primitives and file opening operations also call generateUniqueName
before calling addNode
, I suspect they all call the function twice.
I guess it won't make a difference, but it is probably not the intended behavior.
Upps, lol. Yes, when I saw this issue i thought "that should be a quick fix" so i made the fix, then tried to replicate the bug :P
Nothing big, but I noticed that here and in a few other places
generateUniqueName()
is called before passing the node toaddNode()
, which in turns also callsgenerateUniqueName()
again.