I have this c code:
if(fork()==0){
execl("/usr/bin/fsck", "fsck", "/dev/c0d0p1s0", NULL);
}
it calls execl to run fsck for checking the filesystem /dev/c0d0p1s0.
My question is: how can I get the return value of fsck?
I need the return value of fsck to check whether the file system is consistence or not.
Thank you.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With