X-Git-Url: https://git.distorted.org.uk/~mdw/termux-packages/blobdiff_plain/54af5268c7ee321d192e899cbd60becf731b2ed1..eb1eb8e0fd901ff2c2b4e14dfde4ae56d9f37fbb:/packages/qalc/util.cc.patch diff --git a/packages/qalc/util.cc.patch b/packages/qalc/util.cc.patch index 8fd19df3..5c027565 100644 --- a/packages/qalc/util.cc.patch +++ b/packages/qalc/util.cc.patch @@ -1,6 +1,6 @@ ---- ../libqalculate-1.0.0/libqalculate/util.cc 2017-07-16 12:48:15.000000000 +0200 -+++ ./libqalculate/util.cc 2017-08-08 23:15:29.000000000 +0200 -@@ -937,8 +937,8 @@ +--- ../libqalculate-2.0.0/libqalculate/util.cc 2017-08-27 20:37:20.000000000 +0200 ++++ ./libqalculate/util.cc 2017-08-30 21:33:31.235484528 +0200 +@@ -771,8 +771,8 @@ } void Thread::enableAsynchronousCancel() { @@ -11,12 +11,13 @@ } void *Thread::doRun(void *data) { -@@ -960,7 +960,7 @@ - } +@@ -795,7 +795,8 @@ bool Thread::cancel() { -- int ret = pthread_cancel(m_thread); -+ int ret = pthread_kill(m_thread, 0); - running = (ret != 0); + if(!running) return true; +- running = pthread_cancel(m_thread) != 0; ++ //running = pthread_cancel(m_thread) != 0; ++ running = pthread_kill(m_thread, 0) != 0; return !running; } +