Fix build on gcc2.
(Note, I honestly have no idea what was initially wrong with the code; everything seamt right to me..) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40676 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -83,6 +83,7 @@ spawn_thread(thread_func entry, const char *name, int32 priority, void *data)
|
|||||||
{
|
{
|
||||||
struct thread_creation_attributes attributes;
|
struct thread_creation_attributes attributes;
|
||||||
pthread_thread* thread;
|
pthread_thread* thread;
|
||||||
|
thread_id id;
|
||||||
|
|
||||||
thread = __allocate_pthread(data);
|
thread = __allocate_pthread(data);
|
||||||
if (thread == NULL)
|
if (thread == NULL)
|
||||||
@@ -99,7 +100,7 @@ spawn_thread(thread_func entry, const char *name, int32 priority, void *data)
|
|||||||
attributes.stack_address = NULL;
|
attributes.stack_address = NULL;
|
||||||
attributes.stack_size = 0;
|
attributes.stack_size = 0;
|
||||||
|
|
||||||
thread_id id = _kern_spawn_thread(&attributes);
|
id = _kern_spawn_thread(&attributes);
|
||||||
if (id < 0)
|
if (id < 0)
|
||||||
free(thread);
|
free(thread);
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user