The system() function seems to be returning 128 times the exit code I get from the process it\'s evoking.
From the man page:
RETURN VALUE
0 and 512 are the termination status of the command.
If the command executes successfully, it returns a 0 value, otherwise, it returns a non-zero value. And this non-zero value is various in different OSs. In my mac os, the return value of the second system
command is 256.
You can also get answer from this question `ls` exit status.