Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lorenzo Ferrillo
wine
Commits
08005722
Commit
08005722
authored
13 years ago
by
Akihiro Sagawa
Committed by
Alexandre Julliard
13 years ago
Browse files
Options
Downloads
Patches
Plain Diff
msvcrt: Add semi stub _mbcjmstojis implementation.
parent
fefb5a94
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
dlls/msvcrt/mbcs.c
+17
-0
17 additions, 0 deletions
dlls/msvcrt/mbcs.c
dlls/msvcrt/msvcrt.spec
+1
-1
1 addition, 1 deletion
dlls/msvcrt/msvcrt.spec
dlls/msvcrt/tests/string.c
+33
-0
33 additions, 0 deletions
dlls/msvcrt/tests/string.c
with
51 additions
and
1 deletion
dlls/msvcrt/mbcs.c
+
17
−
0
View file @
08005722
...
...
@@ -463,6 +463,23 @@ unsigned int CDECL _mbcjistojms(unsigned int c)
return
c
;
}
/*********************************************************************
* _mbcjmstojis(MSVCRT.@)
*
* Converts a sjis character to jis.
*/
unsigned
int
CDECL
_mbcjmstojis
(
unsigned
int
c
)
{
/* Conversion takes place only when codepage is 932.
In all other cases, c is returned unchanged */
if
(
get_mbcinfo
()
->
mbcodepage
==
932
)
{
FIXME
(
"(%x): stub
\n
"
,
c
);
}
return
c
;
}
/*********************************************************************
* _mbsdec(MSVCRT.@)
*/
...
...
This diff is collapsed.
Click to expand it.
dlls/msvcrt/msvcrt.spec
+
1
−
1
View file @
08005722
...
...
@@ -664,7 +664,7 @@
# stub _mbccpy_s_l(ptr long ptr str ptr)
@ cdecl _mbcjistojms (long)
# stub _mbcjistojms_l(long ptr)
@
stub
_mbcjmstojis(long)
@
cdecl
_mbcjmstojis(long)
# stub _mbcjmstojis_l(long ptr)
@ cdecl _mbclen(ptr)
# stub _mbclen_l(ptr ptr)
...
...
This diff is collapsed.
Click to expand it.
dlls/msvcrt/tests/string.c
+
33
−
0
View file @
08005722
...
...
@@ -880,6 +880,38 @@ static void test_mbcjisjms(void)
}
while
(
jisjms
[
i
++
][
0
]
!=
0
);
}
static
void
test_mbcjmsjis
(
void
)
{
/* List of value-pairs to test. The test assumes the last pair to be {0, ..} */
unsigned
int
jmsjis
[][
2
]
=
{
{
0x80fc
,
0
},
{
0x813f
,
0
},
{
0x8140
,
0x2121
},
{
0x817e
,
0x215f
},
{
0x817f
,
0
},
{
0x8180
,
0x2160
},
{
0x819e
,
0x217e
},
{
0x819f
,
0x2221
},
{
0x81fc
,
0x227e
},
{
0x81fd
,
0
},
{
0x9ffc
,
0x5e7e
},
{
0x9ffd
,
0
},
{
0xa040
,
0
},
{
0xdffc
,
0
},
{
0xe040
,
0x5f21
},
{
0xeffc
,
0x7e7e
},
{
0xf040
,
0
},
{
0x21
,
0
},
{
0
,
0
}};
int
cp
[]
=
{
932
,
936
,
939
,
950
,
1361
,
_MB_CP_SBCS
};
unsigned
int
i
,
j
;
int
prev_cp
=
_getmbcp
();
for
(
i
=
0
;
i
<
sizeof
(
cp
)
/
sizeof
(
cp
[
0
]);
i
++
)
{
_setmbcp
(
cp
[
i
]);
for
(
j
=
0
;
jmsjis
[
j
][
0
]
!=
0
;
j
++
)
{
unsigned
int
ret
,
exp
;
ret
=
_mbcjmstojis
(
jmsjis
[
j
][
0
]);
exp
=
(
cp
[
i
]
==
932
)
?
jmsjis
[
j
][
1
]
:
jmsjis
[
j
][
0
];
if
(
cp
[
i
]
==
932
)
todo_wine
ok
(
ret
==
exp
,
"Expected 0x%x, got 0x%x (0x%x, codepage=%d)
\n
"
,
exp
,
ret
,
jmsjis
[
j
][
0
],
cp
[
i
]);
else
ok
(
ret
==
exp
,
"Expected 0x%x, got 0x%x (0x%x, codepage=%d)
\n
"
,
exp
,
ret
,
jmsjis
[
j
][
0
],
cp
[
i
]);
}
}
_setmbcp
(
prev_cp
);
}
static
void
test_mbctombb
(
void
)
{
static
const
unsigned
int
mbcmbb_932
[][
2
]
=
{
...
...
@@ -2105,6 +2137,7 @@ START_TEST(string)
test_strcat_s
();
test__mbsnbcpy_s
();
test_mbcjisjms
();
test_mbcjmsjis
();
test_mbctombb
();
test_ismbclegal
();
test_strtok
();
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment