google / btree

BTree provides a simple, ordered, in-memory data structure for Go programs.
Apache License 2.0
3.93k stars 417 forks source link

fix: remove item may changed clone btree; (i+1) children has new cow,… #57

Closed zhangchuanqing5658 closed 4 months ago

zhangchuanqing5658 commented 4 months ago

bug flow new btree t1 clone btree t2 remove item and need merge i + 1 children. now, i + 1 children has new cow, but no copy; t1 modiyf i + 1 children item, t2 follow modify (bug happen).

fix: when merge i + 1 children, copy it

google-cla[bot] commented 4 months ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

zhangchuanqing5658 commented 4 months ago

so sad。。。 terrible bug,but can not fix just google cla , I will create a new request