php - exit status of ./a.out (c compiled code) on running it -


i have c compiled code.
i using

exec('./a.out 2>&1',$out,$ret);
in php script return type want know first whether ran fine or went wrong segmentation fault or infinite loop or that.
basically want know exit status 0,1 , 2 , there significance.
if other exit status exist please tell also..

php puts exit status of exec()ed program $ret variable. program has exited iff $ret becomes 0 after exec() returns.


Comments