https://bugs.winehq.org/show_bug.cgi?id=51227
Bug ID: 51227 Summary: urlmon:url breaks the wininet:http test on Windows 10 1709+ Product: Wine Version: 6.8 Hardware: x86-64 OS: Windows Status: NEW Severity: normal Priority: P2 Component: wininet Assignee: wine-bugs@winehq.org Reporter: fgouget@codeweavers.com
WineTest shows that wininet:http has the following set of failures on Windows 10 1709+:
https://test.winehq.org/data/patterns.html#wininet:http
http.c:6732: Test failed: expected secure flag to be set http.c:6742: Test failed: InternetQueryOption failed: 12016 http.c:6748: Test failed: InternetQueryOption failed: 12016 http.c:6771: Test failed: InternetQueryOption failed: 12016 http.c:6776: Test failed: InternetQueryOption failed: 12016 http.c:6779: Test failed: expected same string
However, when run on its own, the test always succeeds!
Further testing shows that to reproduce the failure one must first run urlmon:url. More specifically:
urlmon_test.exe url wininet_test.exe http -> fails wininet_test.exe http -> succeeds
So urlmon:url breaks the wininet:http that follows, but wininet:http fixes whatever urlmon:url broke so that the next wininet:http run succeeds.
So it seems like there are two bugs: * urlmon:url does not correctly clean up one of the changes it makes. * And wininet:http performs a similar change but instead of restoring the configuration as it was when the test started, it restores the default Windows configuration.
https://bugs.winehq.org/show_bug.cgi?id=51227
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |source, testcase
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #1 from François Gouget fgouget@codeweavers.com --- More specifically it is this call that breaks wininet:http:
test_BindToStorage(HTTPS_TEST, 0, TYMED_ISTREAM);
https://source.winehq.org/git/wine.git/blob/0807b09cfa7f2446f7a69f99ff1006e8...
Everything else in urlmon:url can be run without impacting wininet:http, but the call above on its own is sufficient to break it. Unfortunately test_BindToStorage() is called many times with various parameter combinations.
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #2 from François Gouget fgouget@codeweavers.com --- Created attachment 70589 --> https://bugs.winehq.org/attachment.cgi?id=70589 Comment out all unrelated tests
This patch comments out all the tests unrelated to this failure to simplify reproducing and debugging it.
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #3 from François Gouget fgouget@codeweavers.com --- This also breaks the new wininet:http test that was added in 64728c618f73 on 2021-10-11. https://www.winehq.org/pipermail/wine-devel/2021-October/199121.html
https://bugs.winehq.org/show_bug.cgi?id=51227
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|urlmon:url breaks the |urlmon:url breaks the |wininet:http test on |wininet:http test on |Windows 10 1709+ |Windows 10 1709+ (7 | |failures)
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #4 from François Gouget fgouget@codeweavers.com --- Nowadays there is an extra line:
http.c:6917: Test failed: expected secure flag to be set http.c:6924: Test failed: InternetQueryOption failed: 12019 http.c:6934: Test failed: InternetQueryOption failed: 12016 http.c:6940: Test failed: InternetQueryOption failed: 12016 http.c:6963: Test failed: InternetQueryOption failed: 12016 http.c:6968: Test failed: InternetQueryOption failed: 12016 http.c:6971: Test failed: expected same string
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #5 from Hans Leidekker hans@meelstraat.net --- Adding BINDF_NOWRITECACHE to the bind flags in the urlmon https tests gets rid of the wininet test failures. At the same time it introduces an unexpected OnProgress_FINDINGRESOURCE call, though only on 64-bit Windows 10 1507. I think we can address that by passing BINDTEST_ALLOW_FINDINGRESOURCE as it's done elsewhere in this file.
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #6 from Hans Leidekker hans@meelstraat.net --- Created attachment 73850 --> https://bugs.winehq.org/attachment.cgi?id=73850 patch
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #7 from François Gouget fgouget@codeweavers.com --- I must say I'm not seeing the link between BindToStorage(...BINDF_NOWRITECACHE...) and InternetQueryOptionA(...INTERNET_OPTION_SECURITY_FLAGS...). But I don't really know anything about either.
In any case the patch seems to fix the issue and not cause new failures elsewhere: https://testbot.winehq.org/JobDetails.pl?Key=128298
Does that mean it's a suitable fix? Or should wininet:http be more resilient?
https://bugs.winehq.org/show_bug.cgi?id=51227
--- Comment #8 from Hans Leidekker hans@meelstraat.net --- (In reply to François Gouget from comment #7)
I must say I'm not seeing the link between BindToStorage(...BINDF_NOWRITECACHE...) and InternetQueryOptionA(...INTERNET_OPTION_SECURITY_FLAGS...). But I don't really know anything about either.
In any case the patch seems to fix the issue and not cause new failures elsewhere: https://testbot.winehq.org/JobDetails.pl?Key=128298
Does that mean it's a suitable fix? Or should wininet:http be more resilient?
Fixing wininet:http is better because the URL could be cached in other ways. The fix for wininet:http was committed BTW.
https://bugs.winehq.org/show_bug.cgi?id=51227
Hans Leidekker hans@meelstraat.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Fixed by SHA1| |3c060b0ac0df12eb774c9a8ac92 | |9ed93a70c8600 Resolution|--- |FIXED
--- Comment #9 from Hans Leidekker hans@meelstraat.net --- Fixed with 3c060b0ac0df12eb774c9a8ac929ed93a70c8600.
https://bugs.winehq.org/show_bug.cgi?id=51227
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #10 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 8.0-rc5.