aboutsummaryrefslogtreecommitdiffstats
path: root/erts
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2011-09-19 11:50:33 +0200
committerRickard Green <[email protected]>2011-09-19 11:50:33 +0200
commit171407b6afb043c7d56fb78c8692fab3b99c4be6 (patch)
tree4496e6b3443f07cd7298ccc39784c8919244055c /erts
parent307c06863caebcd63f98c010a31a0263890af9b4 (diff)
parentf7da0d1019e3349c1ec9d55bd3a7d1948b92fc19 (diff)
downloadotp-171407b6afb043c7d56fb78c8692fab3b99c4be6.tar.gz
otp-171407b6afb043c7d56fb78c8692fab3b99c4be6.tar.bz2
otp-171407b6afb043c7d56fb78c8692fab3b99c4be6.zip
Merge branch 'rickard/glibc-mutex-destroy-bug/OTP-9373' into dev
* rickard/glibc-mutex-destroy-bug/OTP-9373: Do not abort emulator when buggy pthread impl return EBUSY
Diffstat (limited to 'erts')
-rw-r--r--erts/emulator/beam/erl_threads.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/erts/emulator/beam/erl_threads.h b/erts/emulator/beam/erl_threads.h
index 8c9cace0c5..a0eda61ba5 100644
--- a/erts/emulator/beam/erl_threads.h
+++ b/erts/emulator/beam/erl_threads.h
@@ -571,8 +571,9 @@ erts_mtx_destroy(erts_mtx_t *mtx)
"Most likely a bug in pthread implementation.";
erts_send_warning_to_logger_str_nogl(warn);
}
+ else
#endif
- erts_thr_fatal_error(res, "destroy mutex");
+ erts_thr_fatal_error(res, "destroy mutex");
}
#endif
}
@@ -675,8 +676,9 @@ erts_cnd_destroy(erts_cnd_t *cnd)
"Most likely a bug in pthread implementation.";
erts_send_warning_to_logger_str_nogl(warn);
}
+ else
#endif
- erts_thr_fatal_error(res, "destroy condition variable");
+ erts_thr_fatal_error(res, "destroy condition variable");
}
#endif
}
@@ -810,8 +812,9 @@ erts_rwmtx_destroy(erts_rwmtx_t *rwmtx)
"Most likely a bug in pthread implementation.";
erts_send_warning_to_logger_str_nogl(warn);
}
+ else
#endif
- erts_thr_fatal_error(res, "destroy rwmutex");
+ erts_thr_fatal_error(res, "destroy rwmutex");
}
#endif
}
@@ -1496,8 +1499,9 @@ erts_spinlock_destroy(erts_spinlock_t *lock)
"Most likely a bug in pthread implementation.";
erts_send_warning_to_logger_str_nogl(warn);
}
+ else
#endif
- erts_thr_fatal_error(res, "destroy rwlock");
+ erts_thr_fatal_error(res, "destroy rwlock");
}
#else
(void)lock;
@@ -1614,8 +1618,9 @@ erts_rwlock_destroy(erts_rwlock_t *lock)
"Most likely a bug in pthread implementation.";
erts_send_warning_to_logger_str_nogl(warn);
}
+ else
#endif
- erts_thr_fatal_error(res, "destroy rwlock");
+ erts_thr_fatal_error(res, "destroy rwlock");
}
#else
(void)lock;