Commit 5620d31f authored by Pekka Pessi's avatar Pekka Pessi

su_root.c: su_task_execute() now accepts NULL as return_value pointer

darcs-hash:20080307164634-65a35-c1f8a4d854439de9a1eebef36ed4c9a2e008fe8e.gz
parent a1fd5104
...@@ -327,9 +327,14 @@ int su_task_execute(su_task_r const task, ...@@ -327,9 +327,14 @@ int su_task_execute(su_task_r const task,
int (*function)(void *), void *arg, int (*function)(void *), void *arg,
int *return_value) int *return_value)
{ {
int dummy;
if (function == NULL) if (function == NULL)
return (errno = EFAULT), -1; return (errno = EFAULT), -1;
if (return_value == NULL)
return_value = &dummy;
if (!su_port_own_thread(task->sut_port)) { if (!su_port_own_thread(task->sut_port)) {
return su_port_execute(task, function, arg, return_value); return su_port_execute(task, function, arg, return_value);
} }
......
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