Hi,

I'm maybe lost in the doc searches, but is there a reference explaining the
extended err codes for fpOpen and friends?
I could not find one.

The effort is a Linux/Pentium fifo read by cgi but fails to read a piped
fifo built with RW permission / shared.

cgi:

Program pipe_read;
uses BaseUnix,Unix;
var FD: Cint;
s:string[255];
   begin
       writeln ('Content-type: text/html');
       writeln;
       FD:=fpOpen ('/tmp/BlaBla,O_RdOnly or O_NonBlock);
       writeln ('start...');
       if FD>=0 then
           begin
               fpread(FD,s,255);
               writeln(s);
           end
   else
       Writeln ('Error : ',fpgeterrno);
       Writeln ('The script exited with status : ',fpClose (FD));
       writeln ('done');
end.

Results...
FpMkfifo : -1<- setup fifo pipe,ok
start...3(handle to pipe)
PID > 0<-server returned
The script exited with status : 0


Thanks,

Mike
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to