aboutsummaryrefslogtreecommitdiff
path: root/ftp/axel/files/patch-axel.c
diff options
context:
space:
mode:
Diffstat (limited to 'ftp/axel/files/patch-axel.c')
-rw-r--r--ftp/axel/files/patch-axel.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/ftp/axel/files/patch-axel.c b/ftp/axel/files/patch-axel.c
new file mode 100644
index 000000000000..1bbad1179f25
--- /dev/null
+++ b/ftp/axel/files/patch-axel.c
@@ -0,0 +1,16 @@
+--- axel.c.orig Sun Aug 5 23:40:26 2001
++++ axel.c Sun Aug 5 23:41:19 2001
+@@ -797,10 +797,11 @@
+ void *setup_thread( void *c )
+ {
+ conn_t *conn = c;
++ int oldstate;
+
+ /* Allow this thread to be killed at any time. */
+- pthread_setcancelstate( PTHREAD_CANCEL_ENABLE, NULL );
+- pthread_setcanceltype( PTHREAD_CANCEL_ASYNCHRONOUS, NULL );
++ pthread_setcancelstate( PTHREAD_CANCEL_ENABLE, &oldstate );
++ pthread_setcanceltype( PTHREAD_CANCEL_ASYNCHRONOUS, &oldstate );
+
+ if( conn_setup( conn ) )
+ {