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
d7e91900
Commit
d7e91900
authored
Aug 27, 2021
by
Piotr Caban
Committed by
Alexandre Julliard
Aug 27, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msvcp90: Introduce throw_failure helper.
Signed-off-by:
Piotr Caban
<
piotr@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
93455491
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
20 additions
and
14 deletions
+20
-14
ios.c
dlls/msvcp60/ios.c
+4
-4
msvcp.h
dlls/msvcp60/msvcp.h
+1
-0
cxx.h
dlls/msvcp90/cxx.h
+0
-1
exception.c
dlls/msvcp90/exception.c
+10
-5
ios.c
dlls/msvcp90/ios.c
+4
-4
msvcp90.h
dlls/msvcp90/msvcp90.h
+1
-0
No files found.
dlls/msvcp60/ios.c
View file @
d7e91900
...
...
@@ -4849,13 +4849,13 @@ void __thiscall ios_base_clear_reraise(ios_base *this, IOSB_iostate state, bool
if
(
reraise
)
_CxxThrowException
(
NULL
,
NULL
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE_eofbit
)
throw_
exception
(
EXCEPTION_FAILURE
,
"eofbit is set"
);
throw_
failure
(
"eofbit is set"
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE_failbit
)
throw_
exception
(
EXCEPTION_FAILURE
,
"failbit is set"
);
throw_
failure
(
"failbit is set"
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE_badbit
)
throw_
exception
(
EXCEPTION_FAILURE
,
"badbit is set"
);
throw_
failure
(
"badbit is set"
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE__Hardfail
)
throw_
exception
(
EXCEPTION_FAILURE
,
"_Hardfail is set"
);
throw_
failure
(
"_Hardfail is set"
);
}
/* ?clear@ios_base@std@@QAEXH@Z */
...
...
dlls/msvcp60/msvcp.h
View file @
d7e91900
...
...
@@ -488,3 +488,4 @@ void WINAPI DECLSPEC_NORETURN _CxxThrowException(void*,const cxx_exception_type*
void
__cdecl
DECLSPEC_NORETURN
_Xlength_error
(
const
char
*
);
void
__cdecl
DECLSPEC_NORETURN
_Xmem
(
void
);
void
__cdecl
DECLSPEC_NORETURN
_Xout_of_range
(
const
char
*
);
void
DECLSPEC_NORETURN
throw_failure
(
const
char
*
);
dlls/msvcp90/cxx.h
View file @
d7e91900
...
...
@@ -319,7 +319,6 @@ typedef enum __exception_type {
EXCEPTION
,
EXCEPTION_BAD_CAST
,
EXCEPTION_LOGIC_ERROR
,
EXCEPTION_FAILURE
,
}
exception_type
;
void
throw_exception
(
exception_type
,
const
char
*
);
...
...
dlls/msvcp90/exception.c
View file @
d7e91900
...
...
@@ -1086,11 +1086,6 @@ void throw_exception(exception_type et, const char *str)
MSVCP_logic_error_ctor
(
&
e
,
name
);
_CxxThrowException
(
&
e
,
&
logic_error_cxx_type
);
}
case
EXCEPTION_FAILURE
:
{
failure
e
;
MSVCP_failure_ctor
(
&
e
,
name
);
_CxxThrowException
(
&
e
,
&
failure_cxx_type
);
}
}
}
...
...
@@ -1104,6 +1099,16 @@ void DECLSPEC_NORETURN throw_range_error(const char *str)
_CxxThrowException
(
&
e
,
&
range_error_cxx_type
);
}
/* Internal: throws failure exception */
void
DECLSPEC_NORETURN
throw_failure
(
const
char
*
str
)
{
exception_name
name
=
EXCEPTION_NAME
(
str
);
failure
e
;
MSVCP_failure_ctor
(
&
e
,
name
);
_CxxThrowException
(
&
e
,
&
failure_cxx_type
);
}
void
init_exception
(
void
*
base
)
{
#ifdef __x86_64__
...
...
dlls/msvcp90/ios.c
View file @
d7e91900
...
...
@@ -5266,13 +5266,13 @@ void __thiscall ios_base_clear_reraise(ios_base *this, IOSB_iostate state, bool
if
(
reraise
)
_CxxThrowException
(
NULL
,
NULL
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE_eofbit
)
throw_
exception
(
EXCEPTION_FAILURE
,
"eofbit is set"
);
throw_
failure
(
"eofbit is set"
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE_failbit
)
throw_
exception
(
EXCEPTION_FAILURE
,
"failbit is set"
);
throw_
failure
(
"failbit is set"
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE_badbit
)
throw_
exception
(
EXCEPTION_FAILURE
,
"badbit is set"
);
throw_
failure
(
"badbit is set"
);
else
if
(
this
->
state
&
this
->
except
&
IOSTATE__Hardfail
)
throw_
exception
(
EXCEPTION_FAILURE
,
"_Hardfail is set"
);
throw_
failure
(
"_Hardfail is set"
);
}
/* ?clear@ios_base@std@@QAEXH@Z */
...
...
dlls/msvcp90/msvcp90.h
View file @
d7e91900
...
...
@@ -669,4 +669,5 @@ void __cdecl DECLSPEC_NORETURN _Xlength_error(const char*);
void
__cdecl
DECLSPEC_NORETURN
_Xmem
(
void
);
void
__cdecl
DECLSPEC_NORETURN
_Xout_of_range
(
const
char
*
);
void
__cdecl
DECLSPEC_NORETURN
_Xruntime_error
(
const
char
*
);
void
DECLSPEC_NORETURN
throw_failure
(
const
char
*
);
void
DECLSPEC_NORETURN
throw_range_error
(
const
char
*
);
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