mirror of
https://github.com/palera1n/palera1n.git
synced 2026-10-23 18:49:48 +02:00
1 parent
ff94a8281d
commit
d9dfefadcb
6 files changed
+34
-32
No files matched your search
+7
-5
@@ -25,7 +25,9 @@ void* pongo_helper(void* ptr) {
|
||||
pongo_thr_running = 1;
|
||||
pthread_cleanup_push(thr_cleanup, &pongo_thr_running);
|
||||
wait_for_pongo();
|
||||
palerain_block();
|
||||
while (get_spin()) {
|
||||
sleep(1);
|
||||
}
|
||||
pthread_cleanup_pop(1);
|
||||
return NULL;
|
||||
}
|
||||
@@ -139,7 +141,7 @@ done:
|
||||
#ifdef USE_LIBUSB
|
||||
libusb_unref_device(arg->dev);
|
||||
#endif
|
||||
palerain_unblock();
|
||||
set_spin(0);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -234,7 +236,7 @@ void io_start(stuff_t *stuff)
|
||||
if(r != 0)
|
||||
{
|
||||
ERR("pthread_create: %s", strerror(r));
|
||||
palerain_unblock();
|
||||
set_spin(0);
|
||||
return;
|
||||
}
|
||||
pthread_join(stuff->th, NULL);
|
||||
@@ -246,14 +248,14 @@ void io_stop(stuff_t *stuff)
|
||||
if(r != 0)
|
||||
{
|
||||
ERR("pthread_cancel: %s", strerror(r));
|
||||
palerain_unblock();
|
||||
set_spin(0);
|
||||
return;
|
||||
}
|
||||
r = pthread_join(stuff->th, NULL);
|
||||
if(r != 0)
|
||||
{
|
||||
ERR("pthread_join: %s", strerror(r));
|
||||
palerain_unblock();
|
||||
set_spin(0);
|
||||
return;
|
||||
}
|
||||
#ifdef USE_LIBUSB
|
||||
|
||||
Reference in new issue
Block a user