I'm working on a project where i should build my own shell, the problem is i know the return value of a child process is a number containing a lot of information not just the exit status, and to get the exit status you shuld use the macro WEXITSTATUS, now i'm looking how i can convert a simple integer to the return value of a process in purpose to use WEXITSTATUS and get back that integer,
for example : i have the number 258, i want to do some bit wise shifting then use WEXITSTATUS to get 258, it's like i want to know the number that produce 258 when i use WEXITSTATUS.
Thank you !