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
7d12fbcc
Commit
7d12fbcc
authored
Mar 14, 2007
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Changed some Solaris defines so that we can access the signal error code.
parent
6a514819
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
11 deletions
+12
-11
signal_i386.c
dlls/ntdll/signal_i386.c
+12
-11
No files found.
dlls/ntdll/signal_i386.c
View file @
7d12fbcc
...
...
@@ -59,11 +59,15 @@
#include "thread.h"
#include "wine/library.h"
#include "ntdll_misc.h"
#include "wine/exception.h"
#include "wine/debug.h"
#ifdef HAVE_VALGRIND_MEMCHECK_H
#include <valgrind/memcheck.h>
#endif
#undef ERR
/* Solaris needs to define this */
/***********************************************************************
* signal context platform-specific definitions
*/
...
...
@@ -196,10 +200,7 @@ typedef struct sigcontext SIGCONTEXT;
#ifdef _SCO_DS
#include <sys/regset.h>
#endif
/* Solaris kludge */
#undef ERR
#include <sys/ucontext.h>
#undef ERR
typedef
struct
ucontext
SIGCONTEXT
;
#ifdef _SCO_DS
...
...
@@ -232,6 +233,9 @@ typedef struct ucontext SIGCONTEXT;
#else
#define ESP_sig(context) ((context)->uc_mcontext.gregs[ESP])
#endif
#ifdef ERR
#define ERROR_sig(context) ((context)->uc_mcontext.gregs[ERR])
#endif
#ifdef TRAPNO
#define TRAP_sig(context) ((context)->uc_mcontext.gregs[TRAPNO])
#endif
...
...
@@ -286,9 +290,6 @@ typedef ucontext_t SIGCONTEXT;
#endif
/* __APPLE__ */
#include "wine/exception.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
seh
);
typedef
int
(
*
wine_signal_handler
)(
unsigned
int
sig
);
...
...
@@ -899,7 +900,7 @@ static EXCEPTION_RECORD *setup_exception( SIGCONTEXT *sigcontext, raise_func fun
if
((
char
*
)
stack
>=
(
char
*
)
get_signal_stack
()
&&
(
char
*
)
stack
<
(
char
*
)
get_signal_stack
()
+
signal_stack_size
)
{
ERR
(
"nested exception on signal stack in thread %04x eip %08x esp %08x stack %p-%p
\n
"
,
WINE_
ERR
(
"nested exception on signal stack in thread %04x eip %08x esp %08x stack %p-%p
\n
"
,
GetCurrentThreadId
(),
(
unsigned
int
)
EIP_sig
(
sigcontext
),
(
unsigned
int
)
ESP_sig
(
sigcontext
),
NtCurrentTeb
()
->
Tib
.
StackLimit
,
NtCurrentTeb
()
->
Tib
.
StackBase
);
...
...
@@ -913,7 +914,7 @@ static EXCEPTION_RECORD *setup_exception( SIGCONTEXT *sigcontext, raise_func fun
UINT
diff
=
(
char
*
)
NtCurrentTeb
()
->
Tib
.
StackLimit
-
(
char
*
)
stack
;
if
(
diff
<
4096
)
{
ERR
(
"stack overflow %u bytes in thread %04x eip %08x esp %08x stack %p-%p
\n
"
,
WINE_
ERR
(
"stack overflow %u bytes in thread %04x eip %08x esp %08x stack %p-%p
\n
"
,
diff
,
GetCurrentThreadId
(),
(
unsigned
int
)
EIP_sig
(
sigcontext
),
(
unsigned
int
)
ESP_sig
(
sigcontext
),
NtCurrentTeb
()
->
Tib
.
StackLimit
,
NtCurrentTeb
()
->
Tib
.
StackBase
);
...
...
@@ -1165,7 +1166,7 @@ static void segv_handler( int signal, siginfo_t *siginfo, void *sigcontext )
rec
->
ExceptionCode
=
EXCEPTION_DATATYPE_MISALIGNMENT
;
break
;
default:
ERR
(
"Got unexpected trap %d
\n
"
,
get_trap_code
(
context
)
);
WINE_
ERR
(
"Got unexpected trap %d
\n
"
,
get_trap_code
(
context
)
);
/* fall through */
case
TRAP_x86_NMI
:
/* NMI interrupt */
case
TRAP_x86_DNA
:
/* Device not available exception */
...
...
@@ -1243,7 +1244,7 @@ static void fpe_handler( int signal, siginfo_t *siginfo, void *sigcontext )
rec
->
ExceptionInformation
[
0
]
=
0
;
break
;
default:
ERR
(
"Got unexpected trap %d
\n
"
,
get_trap_code
(
context
)
);
WINE_
ERR
(
"Got unexpected trap %d
\n
"
,
get_trap_code
(
context
)
);
rec
->
ExceptionCode
=
EXCEPTION_FLT_INVALID_OPERATION
;
break
;
}
...
...
@@ -1485,7 +1486,7 @@ void __wine_enter_vm86( CONTEXT *context )
break
;
case
VM86_SIGNAL
:
/* cannot happen because vm86_enter handles this case */
default:
ERR
(
"unhandled result from vm86 mode %x
\n
"
,
res
);
WINE_
ERR
(
"unhandled result from vm86 mode %x
\n
"
,
res
);
continue
;
}
__regs_RtlRaiseException
(
&
rec
,
context
);
...
...
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