English 中文(简体)
似乎随机坠毁的原因?
原标题:Cause of seemingly random crashes in wininet.dll?

I am getting crashes deep in wininet.dll. It crashed trying to read the zero memory location in HTTP_REQUEST_HANDLE_OBJECT::ReleaseConnection

这是否是实际的DLL的ug,不是不当使用所致?

wininet!HTTP_REQUEST_HANDLE_OBJECT::ReleaseConnection+0x60
wininet!HTTP_REQUEST_HANDLE_OBJECT::CloseConnection+0x84
wininet!HTTP_REQUEST_HANDLE_OBJECT::ReadData_Fsm+0x5e8
wininet!CFsm_ReadData::RunSM+0x2e
wininet!CFsm::Run+0x39
wininet!DoFsm+0x25
wininet!HTTP_REQUEST_HANDLE_OBJECT::ReadData+0x38
wininet!HTTP_REQUEST_HANDLE_OBJECT::HttpReadData_Fsm+0x43
wininet!CFsm_HttpReadData::RunSM+0x2e
wininet!CFsm::Run+0x39
wininet!DoFsm+0x25
wininet!HttpReadData+0x67
wininet!ReadFile_Fsm+0x2d
wininet!CFsm_ReadFile::RunSM+0x2b
wininet!CFsm::Run+0x39
wininet!DoFsm+0x25
wininet!InternetReadFile+0x3ca

我正试图下载一个档案。 我请我发言。

InternetReadFile (hFile, lpBuffer, dwNumberOfBytes ToRead, lpdwNumberOfBytesRead);

hFile HINTERNET处理起来的似乎是罚款的(价值为0x00cc0024,似乎为合法),DwNumberOfBytesToRead为20000。

我的缓冲面积为131,000,也是罚款的。

我的法典有99.9999%的时间!

问题回答

http://code>lpdwNumberOfBytesRead。 或者

DWORD *lpdwNumberOfBytesRead = &someDWORDsomewhere;
InternetReadFile (..., lpdwNumberOfBytesRead);

DWORD NumBytes
InternetReadFile (..., &NumBytes);

我有一种感觉是,你在采取第一种方法时,没有给点人留下一些有效的地方。

我发现,问题在于把互联网CloseHandle连接到已经关闭的其他深层。 通常,这只是回报ERROR_INVALID_HANDLE,但在某些情况下,在互联网上或在互联网上坠毁。





相关问题
Undefined reference

I m getting this linker error. I know a way around it, but it s bugging me because another part of the project s linking fine and it s designed almost identically. First, I have namespace LCD. Then I ...

C++ Equivalent of Tidy

Is there an equivalent to tidy for HTML code for C++? I have searched on the internet, but I find nothing but C++ wrappers for tidy, etc... I think the keyword tidy is what has me hung up. I am ...

Template Classes in C++ ... a required skill set?

I m new to C++ and am wondering how much time I should invest in learning how to implement template classes. Are they widely used in industry, or is this something I should move through quickly?

Print possible strings created from a Number

Given a 10 digit Telephone Number, we have to print all possible strings created from that. The mapping of the numbers is the one as exactly on a phone s keypad. i.e. for 1,0-> No Letter for 2->...

typedef ing STL wstring

Why is it when i do the following i get errors when relating to with wchar_t? namespace Foo { typedef std::wstring String; } Now i declare all my strings as Foo::String through out the program, ...

C# Marshal / Pinvoke CBitmap?

I cannot figure out how to marshal a C++ CBitmap to a C# Bitmap or Image class. My import looks like this: [DllImport(@"test.dll", CharSet = CharSet.Unicode)] public static extern IntPtr ...

Window iconification status via Xlib

Is it possible to check with the means of pure X11/Xlib only whether the given window is iconified/minimized, and, if it is, how?

热门标签