fix crash due to mutexes init error & add threads names for debug#131
Merged
ca333 merged 3 commits intoKomodoPlatform:devfrom May 13, 2020
DeckerSU:patch-mutex
Merged
fix crash due to mutexes init error & add threads names for debug#131ca333 merged 3 commits intoKomodoPlatform:devfrom DeckerSU:patch-mutex
ca333 merged 3 commits intoKomodoPlatform:devfrom
DeckerSU:patch-mutex
Conversation
Since LIBC 2.28 fmul exists in math.h, without this commit
we will have following errors during build with _GNU_SOURCE
define:
In file included from OS_portable.h:80,
from OS_nonportable.c:34:
../includes/curve25519.h:43:9: error: conflicting types for 'fmul'
bits320 fmul(const bits320 in2,const bits320 in);
^~~~
- myinfo->notarymutex and myinfo->dpowmutex seems sometimes initialised not correctly. as a result we had following debug messages: [ Decker ] ./dpow/dpow_network.c.1480 (dpow_addnotary): ip = 149.56.30.227 [ Decker ] ./dpow/dpow_network.c.1481 (dpow_addnotary): err_unlock = 22 [ Decker ] ./dpow/dpow_network.c.1418 (dpow_addnotary): ip = x.x.x.x [ Decker ] ./dpow/dpow_network.c.1419 (dpow_addnotary): err_lock = 22 [ Decker ] ./dpow/dpow_network.c.1480 (dpow_addnotary): ip = x.x.x.x [ Decker ] ./dpow/dpow_network.c.1481 (dpow_addnotary): err_unlock = 22 [ Decker ] ./dpow/dpow_network.c.1418 (dpow_addnotary): ip = 149.56.30.227 where 22 means [EINVAL] The value specified by mutex does not refer to an initialized mutex object. And finally it leads to app crash: iguana: ../nptl/pthread_mutex_lock.c:433: __pthread_mutex_lock_full: Assertion `INTERNAL_SYSCALL_ERRNO (e, __err) != ESRCH || !robust' failed. So, we changed these mutexes to: myinfo->dpowmutex -> def_dpowmutex myinfo->notarymutex -> def_notarymutex with initialisation with PTHREAD_MUTEX_INITIALIZER .
ca333
approved these changes
May 13, 2020
tonymorony
approved these changes
May 13, 2020
Contributor
|
seems to be working for last 4 hours, thanks. |
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.
@tonymorony
this PR should be tested once again before merge, it's related to iguana crash like this:
also, it adding thread names for each iguana thread. example: