]> granicus.if.org Git - pdns/commitdiff
fix for mtasker on solaris
authorBert Hubert <bert.hubert@netherlabs.nl>
Sat, 3 Sep 2005 11:42:25 +0000 (11:42 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Sat, 3 Sep 2005 11:42:25 +0000 (11:42 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@471 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/mtasker.cc

index 53b557fde6559332f448ea7204f1ad7bbb633090..4b292f7baebb920f412d4dc5f8d3861ef16343f0 100644 (file)
@@ -237,7 +237,8 @@ template<class Key, class Val>void MTasker<Key,Val>::makeThread(tfunc_t *start,
   
   uc->uc_stack.ss_size = d_stacksize;
 #ifdef SOLARIS
-  makecontext (uc, (void (*)(...))threadWrapper, 4, this, start, d_maxtid, val);
+  uc->uc_stack.ss_sp = (void*)(((char*)uc->uc_stack.ss_sp)+d_stacksize);
+  makecontext (uc,(void (*)(...))threadWrapper, 5, this, start, d_maxtid, val);
 #else
   makecontext (uc, (void (*)(void))threadWrapper, 4, this, start, d_maxtid, val);
 #endif