WinAPI:InternetCloseHandle函数关闭句柄,但不关闭连接 [英] WinAPI: InternetCloseHandle function closes the handle but not the connection
本文介绍了WinAPI:InternetCloseHandle函数关闭句柄,但不关闭连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我致电 wininet \ InternetOpenUrlA ,然后是wininet \ InternetReadFile,完成后,我呼叫
I call wininet\InternetOpenUrlA, then wininet\InternetReadFile and when I'm done I call wininet\InternetCloseHandle which returns True. That means that the handle successfully closed, but the connection is still in established state.
为什么在我呼叫wininet \ InternetCloseHandle时连接没有关闭?
Why doesn't the connection close when I call wininet\InternetCloseHandle ?
推荐答案
WinInet可以缓存和重用连接,以供将来对同一服务器的请求使用.
WinInet can cache and reuse connections for future requests to the same server.
这篇关于WinAPI:InternetCloseHandle函数关闭句柄,但不关闭连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文