~ubuntu-branches/ubuntu/wily/libuv1/wily

« back to all changes in this revision

Viewing changes to debian/patches/mips-408-process_wait.diff

  • Committer: Package Import Robot
  • Author(s): Luca Bruno
  • Date: 2015-07-07 17:38:16 UTC
  • Revision ID: package-import@ubuntu.com-20150707173816-h9upqypukrdoqyd0
Tags: 1.6.1-3
testsuite: attempt at fixing test runner on mips/mipsel

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
--- a/test/runner-unix.c
 
2
+++ b/test/runner-unix.c
 
3
@@ -173,6 +173,7 @@
 
4
   process_info_t* p;
 
5
   dowait_args args;
 
6
   pthread_t tid;
 
7
+  pthread_attr_t attr;
 
8
   struct timeval tv;
 
9
   fd_set fds;
 
10
 
 
11
@@ -199,7 +200,17 @@
 
12
     return -1;
 
13
   }
 
14
 
 
15
-  r = pthread_create(&tid, NULL, dowait, &args);
 
16
+  if (pthread_attr_init(&attr))
 
17
+    abort();
 
18
+
 
19
+  if (pthread_attr_setstacksize(&attr, 256 * 1024))
 
20
+    abort();
 
21
+
 
22
+  r = pthread_create(&tid, &attr, dowait, &args);
 
23
+
 
24
+  if (pthread_attr_destroy(&attr))
 
25
+    abort();
 
26
+
 
27
   if (r) {
 
28
     perror("pthread_create()");
 
29
     retval = -1;