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
210e1abb
Commit
210e1abb
authored
Jan 18, 2004
by
Eric Pouech
Committed by
Alexandre Julliard
Jan 18, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added support for Unix code page in NTDLL.
parent
30acf519
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
28 additions
and
4 deletions
+28
-4
locale.c
dlls/kernel/locale.c
+3
-2
ntdll.spec
dlls/ntdll/ntdll.spec
+1
-1
ntdll_misc.h
dlls/ntdll/ntdll_misc.h
+5
-0
rtlstr.c
dlls/ntdll/rtlstr.c
+19
-1
No files found.
dlls/kernel/locale.c
View file @
210e1abb
...
@@ -2389,7 +2389,8 @@ int WINAPI lstrcmpiW(LPCWSTR str1, LPCWSTR str2)
...
@@ -2389,7 +2389,8 @@ int WINAPI lstrcmpiW(LPCWSTR str1, LPCWSTR str2)
*/
*/
void
LOCALE_Init
(
void
)
void
LOCALE_Init
(
void
)
{
{
extern
void
__wine_init_codepages
(
const
union
cptable
*
ansi_cp
,
const
union
cptable
*
oem_cp
);
extern
void
__wine_init_codepages
(
const
union
cptable
*
ansi_cp
,
const
union
cptable
*
oem_cp
,
const
union
cptable
*
unix_cp
);
UINT
ansi_cp
=
1252
,
oem_cp
=
437
,
mac_cp
=
10000
,
unix_cp
=
~
0U
;
UINT
ansi_cp
=
1252
,
oem_cp
=
437
,
mac_cp
=
10000
,
unix_cp
=
~
0U
;
LCID
lcid
=
init_default_lcid
(
&
unix_cp
);
LCID
lcid
=
init_default_lcid
(
&
unix_cp
);
...
@@ -2418,7 +2419,7 @@ void LOCALE_Init(void)
...
@@ -2418,7 +2419,7 @@ void LOCALE_Init(void)
unix_cptable
=
wine_cp_get_table
(
28591
);
unix_cptable
=
wine_cp_get_table
(
28591
);
}
}
__wine_init_codepages
(
ansi_cptable
,
oem_cptable
);
__wine_init_codepages
(
ansi_cptable
,
oem_cptable
,
unix_cptable
);
TRACE
(
"ansi=%03d oem=%03d mac=%03d unix=%03d
\n
"
,
TRACE
(
"ansi=%03d oem=%03d mac=%03d unix=%03d
\n
"
,
ansi_cptable
->
info
.
codepage
,
oem_cptable
->
info
.
codepage
,
ansi_cptable
->
info
.
codepage
,
oem_cptable
->
info
.
codepage
,
...
...
dlls/ntdll/ntdll.spec
View file @
210e1abb
...
@@ -1076,7 +1076,7 @@
...
@@ -1076,7 +1076,7 @@
@ cdecl wine_server_send_fd(long)
@ cdecl wine_server_send_fd(long)
# Codepages
# Codepages
@ cdecl __wine_init_codepages(ptr ptr)
@ cdecl __wine_init_codepages(ptr ptr
ptr
)
# signal handling
# signal handling
@ cdecl __wine_set_signal_handler(long ptr)
@ cdecl __wine_set_signal_handler(long ptr)
...
...
dlls/ntdll/ntdll_misc.h
View file @
210e1abb
...
@@ -102,4 +102,9 @@ typedef BOOL (*HANDLERPROC)(LPVOID, LPCVOID);
...
@@ -102,4 +102,9 @@ typedef BOOL (*HANDLERPROC)(LPVOID, LPCVOID);
extern
BOOL
VIRTUAL_SetFaultHandler
(
LPCVOID
addr
,
HANDLERPROC
proc
,
LPVOID
arg
);
extern
BOOL
VIRTUAL_SetFaultHandler
(
LPCVOID
addr
,
HANDLERPROC
proc
,
LPVOID
arg
);
extern
DWORD
VIRTUAL_HandleFault
(
LPCVOID
addr
);
extern
DWORD
VIRTUAL_HandleFault
(
LPCVOID
addr
);
/* code pages */
extern
int
ntdll_umbstowcs
(
DWORD
flags
,
const
char
*
src
,
int
srclen
,
WCHAR
*
dst
,
int
dstlen
);
extern
int
ntdll_wcstoumbs
(
DWORD
flags
,
const
WCHAR
*
src
,
int
srclen
,
char
*
dst
,
int
dstlen
,
const
char
*
defchar
,
int
*
used
);
#endif
#endif
dlls/ntdll/rtlstr.c
View file @
210e1abb
...
@@ -44,19 +44,37 @@ BYTE NlsMbOemCodePageTag = 0;
...
@@ -44,19 +44,37 @@ BYTE NlsMbOemCodePageTag = 0;
static
const
union
cptable
*
ansi_table
;
static
const
union
cptable
*
ansi_table
;
static
const
union
cptable
*
oem_table
;
static
const
union
cptable
*
oem_table
;
static
const
union
cptable
*
unix_table
;
/* NULL if UTF8 */
/**************************************************************************
/**************************************************************************
* __wine_init_codepages (NTDLL.@)
* __wine_init_codepages (NTDLL.@)
*
*
* Set the code page once kernel32 is loaded. Should be done differently.
* Set the code page once kernel32 is loaded. Should be done differently.
*/
*/
void
__wine_init_codepages
(
const
union
cptable
*
ansi
,
const
union
cptable
*
oem
)
void
__wine_init_codepages
(
const
union
cptable
*
ansi
,
const
union
cptable
*
oem
,
const
union
cptable
*
ucp
)
{
{
ansi_table
=
ansi
;
ansi_table
=
ansi
;
oem_table
=
oem
;
oem_table
=
oem
;
unix_table
=
ucp
;
NlsAnsiCodePage
=
ansi
->
info
.
codepage
;
NlsAnsiCodePage
=
ansi
->
info
.
codepage
;
}
}
int
ntdll_umbstowcs
(
DWORD
flags
,
const
char
*
src
,
int
srclen
,
WCHAR
*
dst
,
int
dstlen
)
{
return
(
unix_table
)
?
wine_cp_mbstowcs
(
unix_table
,
flags
,
src
,
srclen
,
dst
,
dstlen
)
:
wine_utf8_mbstowcs
(
flags
,
src
,
srclen
,
dst
,
dstlen
);
}
int
ntdll_wcstoumbs
(
DWORD
flags
,
const
WCHAR
*
src
,
int
srclen
,
char
*
dst
,
int
dstlen
,
const
char
*
defchar
,
int
*
used
)
{
return
(
unix_table
)
?
wine_cp_wcstombs
(
unix_table
,
flags
,
src
,
srclen
,
dst
,
dstlen
,
defchar
,
used
)
:
wine_utf8_wcstombs
(
src
,
srclen
,
dst
,
dstlen
);
}
/**************************************************************************
/**************************************************************************
* RtlInitAnsiString (NTDLL.@)
* RtlInitAnsiString (NTDLL.@)
...
...
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