This repository has been archived by the owner on Apr 22, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
buffer: fix map and set parent to undefined
In 4c9b30d removal of the prototype attributes meant NativeBuffer() no longer had the same object map as Buffer(). By now setting the same properties in the same order both constructors will produce the same map. The same commit changed "parent" from undefined to null. This caused a failure in Buffer#slice() where it was checked if parent === undefined. Causing the incorrect parent to be set. Signed-off-by: Trevor Norris <trev.norris@gmail.com>
- Loading branch information
7c3c51b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops. I missed this...... I guess I just copied the code from our internal blog so I'll blame @JacksonTian for this. ;) Thanks for the fix!