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
c8368cf4
Commit
c8368cf4
authored
Jul 16, 2015
by
Iván Matellanes
Committed by
Alexandre Julliard
Jul 17, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msvcirt: Implement ios::unsetf.
parent
968d07dd
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
2 deletions
+19
-2
msvcirt.c
dlls/msvcirt/msvcirt.c
+8
-2
msvcirt.c
dlls/msvcirt/tests/msvcirt.c
+11
-0
No files found.
dlls/msvcirt/msvcirt.c
View file @
c8368cf4
...
...
@@ -1176,8 +1176,14 @@ void __cdecl ios_unlockc(void)
DEFINE_THISCALL_WRAPPER
(
ios_unsetf
,
8
)
LONG
__thiscall
ios_unsetf
(
ios
*
this
,
LONG
flags
)
{
FIXME
(
"(%p %x) stub
\n
"
,
this
,
flags
);
return
0
;
LONG
prev
=
this
->
flags
;
TRACE
(
"(%p %x)
\n
"
,
this
,
flags
);
ios_lock
(
this
);
this
->
flags
&=
~
flags
;
ios_unlock
(
this
);
return
prev
;
}
/* ?width@ios@@QAEHH@Z */
...
...
dlls/msvcirt/tests/msvcirt.c
View file @
c8368cf4
...
...
@@ -141,6 +141,7 @@ static LONG (*__thiscall p_ios_flags_set)(ios*, LONG);
static
LONG
(
*
__thiscall
p_ios_flags_get
)(
const
ios
*
);
static
LONG
(
*
__thiscall
p_ios_setf
)(
ios
*
,
LONG
);
static
LONG
(
*
__thiscall
p_ios_setf_mask
)(
ios
*
,
LONG
,
LONG
);
static
LONG
(
*
__thiscall
p_ios_unsetf
)(
ios
*
,
LONG
);
/* Emulate a __thiscall */
#ifdef __i386__
...
...
@@ -253,6 +254,7 @@ static BOOL init(void)
SET
(
p_ios_flags_get
,
"?flags@ios@@QEBAJXZ"
);
SET
(
p_ios_setf
,
"?setf@ios@@QEAAJJ@Z"
);
SET
(
p_ios_setf_mask
,
"?setf@ios@@QEAAJJJ@Z"
);
SET
(
p_ios_unsetf
,
"?unsetf@ios@@QEAAJJ@Z"
);
}
else
{
p_operator_new
=
(
void
*
)
GetProcAddress
(
msvcrt
,
"??2@YAPAXI@Z"
);
...
...
@@ -295,6 +297,7 @@ static BOOL init(void)
SET
(
p_ios_flags_get
,
"?flags@ios@@QBEJXZ"
);
SET
(
p_ios_setf
,
"?setf@ios@@QAEJJ@Z"
);
SET
(
p_ios_setf_mask
,
"?setf@ios@@QAEJJJ@Z"
);
SET
(
p_ios_unsetf
,
"?unsetf@ios@@QAEJJ@Z"
);
}
SET
(
p_ios_static_lock
,
"?x_lockc@ios@@0U_CRT_CRITICAL_SECTION@@A"
);
SET
(
p_ios_lockc
,
"?lockc@ios@@KAXXZ"
);
...
...
@@ -1020,6 +1023,14 @@ static void test_ios(void)
ret
=
(
LONG
)
call_func3
(
p_ios_setf_mask
,
&
ios_obj
,
0x111
,
0x105
);
ok
(
ret
==
0x8444
,
"expected %x got %x
\n
"
,
0x8444
,
ret
);
ok
(
ios_obj
.
flags
==
0x8541
,
"expected %x got %x
\n
"
,
0x8541
,
ios_obj
.
flags
);
/* unsetf */
ret
=
(
LONG
)
call_func2
(
p_ios_unsetf
,
&
ios_obj
,
0x1111
);
ok
(
ret
==
0x8541
,
"expected %x got %x
\n
"
,
0x8541
,
ret
);
ok
(
ios_obj
.
flags
==
0x8440
,
"expected %x got %x
\n
"
,
0x8440
,
ios_obj
.
flags
);
ret
=
(
LONG
)
call_func2
(
p_ios_unsetf
,
&
ios_obj
,
0x8008
);
ok
(
ret
==
0x8440
,
"expected %x got %x
\n
"
,
0x8440
,
ret
);
ok
(
ios_obj
.
flags
==
0x440
,
"expected %x got %x
\n
"
,
0x440
,
ios_obj
.
flags
);
ios_obj
.
do_lock
=
-
1
;
SetEvent
(
lock_arg
.
release
[
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