This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

where is cygwin_attach_handle_to_fd?


I am trying to read from com port 19.  I could not seem to does this with the 
standard cygwin open () call.  So I am going to use CreateFile file but of 
couse this gives me a HANDLE.  Now cygwin_attach_handle_to_fd () is supposed 
to be able to covert the HANDLE to a fd so that my unix functions can read 
them but I can not seem to find the cygwin_attanch_handle_to_fd anywhere.  If 
anyone has any experience with this please help me out.

Thanks,
     Charlie Benton (bentonc@mail.utexas.edu)

CreateFile (
        "\\\\.\\COM19",     // address of name of the communications device
        GENERIC_READ,       // access (read-write) mode
        0,                  // share mode
        NULL,               // address of security descriptor
        OPEN_EXISTING,      // how to create
        0,                  // file attributes
        NULL                // handle of file with attributes to copy
);

if (0 < (fd = open(fname, O_RDONLY)))

------------------------------------------------------------
 Get your FREE web-based e-mail and newsgroup access at:
   http://MailAndNews.com and http://MailAndNews.co.uk

 Create a new mailbox, or access your existing IMAP4 or
 POP3 mailbox from anywhere with just a web browser.
------------------------------------------------------------


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]