libgpg-error: Update from 1.27 to 1.29
[termux-packages] / packages / qalc / util.cc.patch
CommitLineData
eb1eb8e0
DM
1--- ../libqalculate-2.0.0/libqalculate/util.cc 2017-08-27 20:37:20.000000000 +0200
2+++ ./libqalculate/util.cc 2017-08-30 21:33:31.235484528 +0200
3@@ -771,8 +771,8 @@
54af5268
DM
4 }
5
6 void Thread::enableAsynchronousCancel() {
7- pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL);
8- pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL);
9+ //pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL);
10+ //pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL);
11 }
12
13 void *Thread::doRun(void *data) {
eb1eb8e0 14@@ -795,7 +795,8 @@
54af5268
DM
15
16 bool Thread::cancel() {
eb1eb8e0
DM
17 if(!running) return true;
18- running = pthread_cancel(m_thread) != 0;
19+ //running = pthread_cancel(m_thread) != 0;
20+ running = pthread_kill(m_thread, 0) != 0;
54af5268
DM
21 return !running;
22 }
eb1eb8e0 23