Skip to content

Fixed an issue where large buffer allocations in filters (> 256MB) causes a segfault#1368

Merged
implausible merged 4 commits into
nodegit:masterfrom
cjhoward92:fix_large_buffer_crashes
Sep 13, 2017
Merged

Fixed an issue where large buffer allocations in filters (> 256MB) causes a segfault#1368
implausible merged 4 commits into
nodegit:masterfrom
cjhoward92:fix_large_buffer_crashes

Conversation

@cjhoward92
Copy link
Copy Markdown
Contributor

In GitBuf::Set and GitBuf::Grow the buffers could only accept a maximum buffer of 256MB because of limits with v8 string sizes. Removed the conversion to string in those methods to allow for larger buffers.

Also removed some special case logic in the async_functions template that would prevent proper buffer method generation, and then updated descriptors for methods that require proper buffer allocations to be "shouldAlloc": true

@implausible implausible force-pushed the fix_large_buffer_crashes branch 5 times, most recently from 9a4a6d7 to 9febe5d Compare September 13, 2017 15:29
@implausible implausible force-pushed the fix_large_buffer_crashes branch from 9febe5d to 658f5b7 Compare September 13, 2017 15:49
@implausible implausible merged commit d77f418 into nodegit:master Sep 13, 2017
@cjhoward92 cjhoward92 deleted the fix_large_buffer_crashes branch October 16, 2017 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants