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
97847eee
Commit
97847eee
authored
Aug 24, 2020
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Avoid referencing winecrt0 exception handlers from the Unix library.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6844ff8a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
17 deletions
+10
-17
virtual.c
dlls/ntdll/unix/virtual.c
+6
-4
exception.h
include/wine/exception.h
+4
-13
No files found.
dlls/ntdll/unix/virtual.c
View file @
97847eee
...
...
@@ -92,6 +92,8 @@ struct file_view
unsigned
int
protect
;
/* protection for all pages at allocation time and SEC_* flags */
};
#define __EXCEPT_SYSCALL __EXCEPT_HANDLER(0)
/* per-page protection flags */
#define VPROT_READ 0x01
#define VPROT_WRITE 0x02
...
...
@@ -3142,7 +3144,7 @@ BOOL virtual_check_buffer_for_read( const void *ptr, SIZE_T size )
dummy
=
p
[
0
];
dummy
=
p
[
count
-
1
];
}
__EXCEPT_
PAGE_FAULT
__EXCEPT_
SYSCALL
{
return
FALSE
;
}
...
...
@@ -3175,7 +3177,7 @@ BOOL virtual_check_buffer_for_write( void *ptr, SIZE_T size )
p
[
0
]
|=
0
;
p
[
count
-
1
]
|=
0
;
}
__EXCEPT_
PAGE_FAULT
__EXCEPT_
SYSCALL
{
return
FALSE
;
}
...
...
@@ -3197,7 +3199,7 @@ BOOL WINAPI IsBadStringPtrA( LPCSTR str, UINT_PTR max )
volatile
const
char
*
p
=
str
;
while
(
p
!=
str
+
max
)
if
(
!*
p
++
)
break
;
}
__EXCEPT_
PAGE_FAULT
__EXCEPT_
SYSCALL
{
return
TRUE
;
}
...
...
@@ -3219,7 +3221,7 @@ BOOL WINAPI IsBadStringPtrW( LPCWSTR str, UINT_PTR max )
volatile
const
WCHAR
*
p
=
str
;
while
(
p
!=
str
+
max
)
if
(
!*
p
++
)
break
;
}
__EXCEPT_
PAGE_FAULT
__EXCEPT_
SYSCALL
{
return
TRUE
;
}
...
...
include/wine/exception.h
View file @
97847eee
...
...
@@ -163,27 +163,18 @@ extern DWORD __cdecl __wine_finally_ctx_handler( EXCEPTION_RECORD *record,
const __WINE_FRAME * const __eptr __attribute__((unused)) = &__f; \
do {
/* convenience handler for page fault exceptions */
#define __EXCEPT_PAGE_FAULT \
#define __EXCEPT_HANDLER(handler) \
} while(0); \
__wine_pop_frame( &__f.frame ); \
break; \
} else { \
__f.frame.Handler =
__wine_exception_handler_page_fault
; \
__f.frame.Handler =
(handler)
; \
if (__wine_setjmpex( &__f.jmp, &__f.frame )) { \
const __WINE_FRAME * const __eptr __attribute__((unused)) = &__f; \
do {
/* convenience handler for all exceptions */
#define __EXCEPT_ALL \
} while(0); \
__wine_pop_frame( &__f.frame ); \
break; \
} else { \
__f.frame.Handler = __wine_exception_handler_all; \
if (__wine_setjmpex( &__f.jmp, &__f.frame )) { \
const __WINE_FRAME * const __eptr __attribute__((unused)) = &__f; \
do {
#define __EXCEPT_PAGE_FAULT __EXCEPT_HANDLER(__wine_exception_handler_page_fault)
#define __EXCEPT_ALL __EXCEPT_HANDLER(__wine_exception_handler_all)
#define __ENDTRY \
} while (0); \
...
...
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