[fpc-pascal] FpWaitPid() multiplies status by 256

Anton Shepelev anton.txt at gmail.com
Sat Oct 6 11:59:40 CEST 2018


Hello, all

Can anybody suggest why the function

   function FpWaitPid
   (     pid:     TPid;
     var Status:  cint;
         Options: cint
   ):             TPid;

may  return  the status multiplied by 256?  If my child pro-
cess terminates with Halt(1), the status  is  256,  if  with
Halt(2),  the  status is 512, etc.  I am sorry to say that I
observe it with an old version of  FPC -- 2.6.4+dfsg-4,  be-
cause  it is installed on the remote machine with Debian/GNU
Linux 8 that I use over SSH.  I have requested the maintain-
er  to  upgrade FPC and, if or when he complies, I will test
again.

-- 
Please, do not forward replies to my e-mail.



More information about the fpc-pascal mailing list