nbronson/snaptree — pull request #1 by pcmanus (2011-11-15 20:34:16+00:00)
Title: When cloning, the COWEpoch is not created in the right enclosing object

COWEpoch are inner object. When a CopyOnWriteManager is cloned, the new COWEpoch for the clone is created by the initial object rather than the clone. I believe this is wrong, and leads to problem when later the COWEpoch affects _active (in onClosed), affecting the original object rather than the clone.

The commit includes a small unit test demonstrating the bug (I got lazy and created a SnapTree test bug it's likely possible to simply have CopyOnWriteManagerTest), as well as a simple fix.