Stephen M. Moraco
-
2003-09-08
- assigned_to: nobody --> stephmo
Since the declaration of the system call execi() is
in unistd.h as:
extern pid_t execi(int (*code_start) (int, char **), int
argc, char **argv, priority_t priority, size_t stack_size);
and the definition of the type pid_t is in tm.h as:
typedef size_t pid_t;
and taking into account that the definition of size_t is in
mem.h as:
typedef unsigned size_t;
I guess there is an incompatibility of types since execi()
returns a -1 (signed) if there is a fail.
This can be avoid with a C compilation but not with C++.
So, trying to handle the fail code (-1) from the system
call execi() the C++ compiler shows a warning in the
comparison between signed and unsigned.