Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
c034da78
Commit
c034da78
authored
Mar 26, 2021
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 26, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
urlmon: Fix user agent suffix separator handling.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
f2e50eed
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
10 deletions
+12
-10
session.c
dlls/urlmon/session.c
+9
-10
misc.c
dlls/urlmon/tests/misc.c
+3
-0
No files found.
dlls/urlmon/session.c
View file @
c034da78
...
...
@@ -550,22 +550,22 @@ static size_t obtain_user_agent(unsigned int version, WCHAR *ret, size_t size)
if
(
sizeof
(
void
*
)
==
8
)
#ifdef __x86_64__
os_type
=
L"
Win64; x64;
"
;
os_type
=
L"
; Win64; x64
"
;
#else
os_type
=
L"
Win64;
"
;
os_type
=
L"
; Win64
"
;
#endif
else
if
(
IsWow64Process
(
GetCurrentProcess
(),
&
is_wow
)
&&
is_wow
)
os_type
=
L"
WOW64;
"
;
os_type
=
L"
; WOW64
"
;
else
os_type
=
L""
;
swprintf
(
ret
+
len
,
size
-
len
,
L"Windows %s%d.%d
;
%s"
,
is_nt
,
info
.
dwMajorVersion
,
swprintf
(
ret
+
len
,
size
-
len
,
L"Windows %s%d.%d%s"
,
is_nt
,
info
.
dwMajorVersion
,
info
.
dwMinorVersion
,
os_type
);
len
=
lstrlenW
(
ret
);
if
(
!
quirks
)
{
wcscpy
(
ret
+
len
,
L"Trident/7.0"
);
len
+=
ARRAY_SIZE
(
L"Trident/7.0"
)
-
1
;
wcscpy
(
ret
+
len
,
L"
;
Trident/7.0"
);
len
+=
ARRAY_SIZE
(
L"
;
Trident/7.0"
)
-
1
;
}
if
(
version
<
9
)
{
...
...
@@ -575,10 +575,9 @@ static size_t obtain_user_agent(unsigned int version, WCHAR *ret, size_t size)
DWORD
value_len
,
idx
;
for
(
idx
=
0
;;
idx
++
)
{
if
(
idx
)
{
ret
[
len
++
]
=
';'
;
ret
[
len
++
]
=
' '
;
}
ret
[
len
++
]
=
';'
;
ret
[
len
++
]
=
' '
;
value_len
=
size
-
len
-
2
;
res
=
RegEnumValueW
(
key
,
idx
,
ret
+
len
,
&
value_len
,
NULL
,
NULL
,
NULL
,
NULL
);
if
(
res
!=
ERROR_SUCCESS
)
...
...
dlls/urlmon/tests/misc.c
View file @
c034da78
...
...
@@ -1560,6 +1560,9 @@ static void test_user_agent(void)
if
(
i
==
11
)
{
p
+=
check_prefix
(
p
,
"; rv:11.0) like Gecko"
);
}
else
{
if
(
i
!=
1
)
ok
(
*
p
==
';'
||
*
p
==
')'
,
"unexpected suffix %s for version %u
\n
"
,
wine_dbgstr_a
(
p
),
i
);
if
(
i
<
9
)
p
=
strchr
(
p
,
')'
);
p
+=
check_prefix
(
p
,
")"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment