Open
Conversation
added 3 commits
March 27, 2013 16:30
- number of processors fetched using `pthread_num_processors_np()` (pthreads-w32 extension?) - moved block file support to non-WIN32 conditional inclusion section - conditional includes for some POSIX headers
The actual stack overflow observed occurred in debug mode, with a test file that consists of a repeated pattern. The binary tree dtor used in verificationhashtable.h recursively deletes nodes. Each node deletes its left and right child (fine) and the next node with same crc & hash. But the `same` nodes are not stored in a tree (with log(n) depth) but in a linked list. Therefore, deleting them recursively can lead to a stack overflow (if there are many of them). The fix replaces the recurrence of deletion of `same` nodes by a loop. Left and right child nodes are still deleted using recurrence. This is rather a quick-and-dirty fix, as I don't really know how the tree itself is used from the outside (what's the owner concept? not clear).
The property sheet allows quick adjustment of the pthreads path.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Windows support has been broken due to introduction of some additional POSIX headers, multithreading and block file support. Only some small changes have been necessary to restore it.
pthread_num_processors_np()(pthreads-w32 extension?)