Commit bf006071 authored by 's avatar
Browse files

Corrected passing of the last argument in pthread_create()

git-svn-id: file:///home/svn/mapi/trunk@1342 8d5bb341-7cf1-0310-8cf6-ba355fef3186
parent 0c869ca0
......@@ -216,8 +216,7 @@ mapidrv_create_flow (int devid, int fd, char **devtype)
fprintf (stderr, "pthread_attr_init failed");
return COMBO6_PTHR_ERR;
}
if (pthread_create
(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &devid) != 0)
if (pthread_create(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &(i->id)) != 0)
{
fprintf (stderr, "pthread_create failed");
return COMBO6_PTHR_ERR;
......
......@@ -603,8 +603,7 @@ mapidrv_create_flow (int devid, int fd, char **devtype)
return DAGDRV_PTHR_ERR;
}
if (pthread_create
(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &devid) != 0)
if (pthread_create(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &(i->id)) != 0)
{
DEBUG_CMD(Debug_Message("ERROR: pthread_create failed"));
return DAGDRV_PTHR_ERR;
......
......@@ -237,7 +237,7 @@ mapidrv_create_flow (int devid, int fd, char **devtype)
return NICDRV_PTHR_ERR;
}
if (pthread_create(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &devid) != 0)
if (pthread_create(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &(i->id)) != 0)
{
DEBUG_CMD(Debug_Message("ERROR: pthread_create failed"));
return DAGDRV_PTHR_ERR;
......
......@@ -426,8 +426,8 @@ mapidrv_create_flow (int devid, int fd, char **devtype)
DEBUG_CMD(Debug_Message("ERROR: pthread_attr_init failed"));
return NICDRV_PTHR_ERR;
}
if (pthread_create(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &devid) != 0)
if (pthread_create(&i->th_proc, &i->th_attr, (void *) mapidrv_proc_loop, (void *) &(i->id)) != 0)
{
DEBUG_CMD(Debug_Message("ERROR: pthread_create failed"));
return DAGDRV_PTHR_ERR;
......
......@@ -292,7 +292,7 @@ mapidrv_connect (int devid,int fd)
if (i->th_proc == 0) {
//Start processing thread
if (pthread_create(&i->th_proc, NULL, (void *) mapidrv_proc_loop, (void *) &devid) != 0) {
if (pthread_create(&i->th_proc, NULL, (void *) mapidrv_proc_loop, (void *) &(i->id)) != 0) {
DEBUG_CMD(Debug_Message("ERROR: pthread_create failed"));
return VINDRV_PTHR_ERR;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment