mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
naett: Complete a Windows request when WinHttpWriteData fails
The return value was ignored, and after a synchronous failure no further callback arrives, so the request never completed. During achievement game identification, that blocked boot indefinitely. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
1 parent
21963d4534
commit
3e59842fd9
1 file changed
+6
-1
@@ -219,7 +219,12 @@ callback(HINTERNET request, DWORD_PTR context, DWORD status, LPVOID statusInform
|
||||
int bytesRead = res->request->options.bodyReader(
|
||||
res->buffer, sizeof(res->buffer), res->request->options.bodyReaderData);
|
||||
if (bytesRead) {
|
||||
WinHttpWriteData(request, res->buffer, bytesRead, NULL);
|
||||
// PPSSPP: upstream ignored a failure here, and with no further callback coming,
|
||||
// the request never completed.
|
||||
if (!WinHttpWriteData(request, res->buffer, bytesRead, NULL)) {
|
||||
res->code = naettWriteError;
|
||||
naettSetComplete(res);
|
||||
}
|
||||
} else {
|
||||
if (!WinHttpReceiveResponse(request, NULL)) {
|
||||
res->code = naettReadError;
|
||||
|
||||
Reference in new issue
Block a user