Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
1d6b3e14
Commit
1d6b3e14
authored
Nov 12, 2022
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
win32u: Use RtlGetLastWin32Error() instead of GetLastError().
parent
cc0ac7b4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
7 deletions
+15
-7
env.c
dlls/ntdll/unix/env.c
+8
-0
clipboard.c
dlls/win32u/clipboard.c
+1
-1
spy.c
dlls/win32u/spy.c
+4
-4
window.c
dlls/win32u/window.c
+2
-2
No files found.
dlls/ntdll/unix/env.c
View file @
1d6b3e14
...
...
@@ -2392,6 +2392,14 @@ ULONG WINAPI RtlNtStatusToDosError( NTSTATUS status )
}
/**********************************************************************
* RtlGetLastWin32Error (ntdll.so)
*/
DWORD
WINAPI
RtlGetLastWin32Error
(
void
)
{
return
NtCurrentTeb
()
->
LastErrorValue
;
}
/**********************************************************************
* RtlSetLastWin32Error (ntdll.so)
*/
void
WINAPI
RtlSetLastWin32Error
(
DWORD
err
)
...
...
dlls/win32u/clipboard.c
View file @
1d6b3e14
...
...
@@ -56,7 +56,7 @@ static struct list formats_to_free = LIST_INIT( formats_to_free );
static
const
char
*
debugstr_format
(
UINT
id
)
{
WCHAR
buffer
[
256
];
DWORD
le
=
GetLast
Error
();
DWORD
le
=
RtlGetLastWin32
Error
();
BOOL
r
=
NtUserGetClipboardFormatName
(
id
,
buffer
,
ARRAYSIZE
(
buffer
)
);
RtlSetLastWin32Error
(
le
);
...
...
dlls/win32u/spy.c
View file @
1d6b3e14
...
...
@@ -2213,7 +2213,7 @@ static void SPY_GetWndName( SPY_INSTANCE *sp_e )
const
char
*
debugstr_msg_name
(
UINT
msg
,
HWND
hWnd
)
{
SPY_INSTANCE
ext_sp_e
;
DWORD
save_error
=
GetLast
Error
();
DWORD
save_error
=
RtlGetLastWin32
Error
();
ext_sp_e
.
msgnum
=
msg
;
ext_sp_e
.
msg_hwnd
=
hWnd
;
...
...
@@ -2504,7 +2504,7 @@ static void SPY_DumpStructure(const SPY_INSTANCE *sp_e, BOOL enter)
/* for CUSTOMDRAW, dump all the data for TOOLBARs */
if
(
pnmh
->
code
==
NM_CUSTOMDRAW
)
{
/* save and restore error code over the next call */
save_error
=
GetLast
Error
();
save_error
=
RtlGetLastWin32
Error
();
NtUserGetClassName
(
pnmh
->
hwndFrom
,
FALSE
,
&
str
);
RtlSetLastWin32Error
(
save_error
);
if
(
wcscmp
(
TOOLBARCLASSNAMEW
,
from_class
)
==
0
)
...
...
@@ -2597,7 +2597,7 @@ void spy_enter_message( INT iFlag, HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
{
SPY_INSTANCE
sp_e
;
int
indent
;
DWORD
save_error
=
GetLast
Error
();
DWORD
save_error
=
RtlGetLastWin32
Error
();
if
(
!
spy_init
()
||
exclude_msg
(
msg
))
return
;
...
...
@@ -2652,7 +2652,7 @@ void spy_exit_message( INT iFlag, HWND hWnd, UINT msg, LRESULT lReturn,
{
SPY_INSTANCE
sp_e
;
int
indent
;
DWORD
save_error
=
GetLast
Error
();
DWORD
save_error
=
RtlGetLastWin32
Error
();
if
(
!
TRACE_ON
(
message
)
||
exclude_msg
(
msg
)
||
(
exclude_dwp
()
&&
iFlag
==
SPY_RESULT_DEFWND
))
...
...
dlls/win32u/window.c
View file @
1d6b3e14
...
...
@@ -852,7 +852,7 @@ BOOL is_window_enabled( HWND hwnd )
RtlSetLastWin32Error
(
NO_ERROR
);
ret
=
get_window_long
(
hwnd
,
GWL_STYLE
);
if
(
!
ret
&&
GetLast
Error
()
!=
NO_ERROR
)
return
FALSE
;
if
(
!
ret
&&
RtlGetLastWin32
Error
()
!=
NO_ERROR
)
return
FALSE
;
return
!
(
ret
&
WS_DISABLED
);
}
...
...
@@ -4879,7 +4879,7 @@ static WND *create_window_handle( HWND parent, HWND owner, UNICODE_STRING *name,
if
(
!
handle
)
{
WARN
(
"error %d creating window
\n
"
,
GetLast
Error
()
);
WARN
(
"error %d creating window
\n
"
,
RtlGetLastWin32
Error
()
);
return
NULL
;
}
...
...
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