[fpc-pascal] File Descriptor in Windows ?

fredvs fiens at hotmail.com
Sun Mar 22 18:38:07 CET 2015


> Check for writeln's in the htmlthread unit you added.

Oops, i think i get it (sorry it is Sunday). ;-(
 
- CreatePipeHandles (InHandle,OutHandle, PipeBufferSize);
- Writeln('Input Handle = ' + inttostr(InHandle) + ' Output Handle = ' +
inttostr(OutHandle));
=> Linux => Input Handle = 3 Output Handle = 4
=> Windows => Input Handle = 212 Output Handle = 216

- Output:=TOutputPipeStream.Create (OutHandle);
- if Output = nil then  writeln('===> NO Pipe Stream created.') else
- writeln('===> Output Pipe Stream created.');
=> Linux + Windows => ===> Output Pipe Stream created.

-  err := mpg123_open_fd(MyMPHandle, InHandle);
- if err = 0 then writeln('===> mpg123_open_fd => ok.') else
       writeln('===> mpg123_open_fd NOT ok.') ; 
=> Linux + Windows => mpg123_open_fd => ok. 

- err := mpg123_read(MyMPHandle, blabla);
- writeln('===> mpg123_read error => ' + inttostr(err)) ;
=> Linux => mpg123_read error => 0 => no error
=> Windows => mpg123_read error => 12 => Invalid RVA mode

Ooops, what is RVA mode?...

Thanks.

Fred.







-----
Many thanks ;-)
--
View this message in context: http://free-pascal-general.1045716.n5.nabble.com/File-Descriptor-in-Windows-tp5721448p5721466.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.



More information about the fpc-pascal mailing list