The information in this article applies to:
SYMPTOMS
In asynchronous WinInet mode you open a remote file with the FtpOpenFile function, read it with the InternetReadFile function, and then close the handle returned from FtpOpenFile with the InternetCloseHandle function. InternetCloseHandle returns TRUE. However, if you try to open another file with FtpOpenFile it fails with the error code 12110 (ERROR_FTP_TRANSFER_IN_PROGRESS). If you wait for the state of handle closing before opening another file anyway, you never get the status indication of INTERNET_STATUS_HANDLE_CLOSING from the callback function. The program stops responding. CAUSEInternetReadFile does not reset the refcount on a HANDLE_OBJECT after reaching EOF. RESOLUTIONYou can write a multiple-thread program in synchronous WinInet mode. The primary thread spawns a worker thread, which calls synchronous WinInet functions (blocking) so that the primary thread is free. Use any synchronization mechanisms, such as event object, to synchronize the primary thread and worker thread. STATUSThe bug has been fixed in Internet Explorer 5 and later. There is no need to wait for the callback indication of INTERNET_STATUS_HANDLE_CLOSING before calling another FtpOpenFile if InternetCloseHandle returns TRUE. Additional query words:
Keywords : kbIE400bug kbIE401bug kbIE500fix kbGrpInetServer kbDSupport |
Last Reviewed: October 29, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |