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
6b2c2eb7
Commit
6b2c2eb7
authored
Apr 02, 2019
by
Piotr Caban
Committed by
Alexandre Julliard
Apr 02, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
krnl386.exe16: Get rid of NE_str(n)casecmp helper.
Signed-off-by:
Piotr Caban
<
piotr@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
ea4d756c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
32 deletions
+4
-32
ne_module.c
dlls/krnl386.exe16/ne_module.c
+4
-32
No files found.
dlls/krnl386.exe16/ne_module.c
View file @
6b2c2eb7
...
...
@@ -113,34 +113,6 @@ static inline BOOL contains_path( LPCSTR name )
/***********************************************************************
* NE_strcasecmp
*
* locale-independent case conversion for module lookups
*/
static
int
NE_strcasecmp
(
const
char
*
str1
,
const
char
*
str2
)
{
int
ret
=
0
;
for
(
;
;
str1
++
,
str2
++
)
if
((
ret
=
RtlUpperChar
(
*
str1
)
-
RtlUpperChar
(
*
str2
))
||
!*
str1
)
break
;
return
ret
;
}
/***********************************************************************
* NE_strncasecmp
*
* locale-independent case conversion for module lookups
*/
static
int
NE_strncasecmp
(
const
char
*
str1
,
const
char
*
str2
,
int
len
)
{
int
ret
=
0
;
for
(
;
len
>
0
;
len
--
,
str1
++
,
str2
++
)
if
((
ret
=
RtlUpperChar
(
*
str1
)
-
RtlUpperChar
(
*
str2
))
||
!*
str1
)
break
;
return
ret
;
}
/***********************************************************************
* NE_GetPtr
*/
NE_MODULE
*
NE_GetPtr
(
HMODULE16
hModule
)
...
...
@@ -1461,7 +1433,7 @@ HMODULE16 WINAPI GetModuleHandle16( LPCSTR name )
* 'i' compare is just a quickfix until the loader handles that
* correctly. -MM 990705
*/
if
((
*
name_table
==
len
)
&&
!
NE_strncase
cmp
(
tmpstr
,
(
const
char
*
)
name_table
+
1
,
len
))
if
((
*
name_table
==
len
)
&&
!
_strni
cmp
(
tmpstr
,
(
const
char
*
)
name_table
+
1
,
len
))
return
hModule
;
}
...
...
@@ -1500,7 +1472,7 @@ HMODULE16 WINAPI GetModuleHandle16( LPCSTR name )
loadedfn
--
;
}
/* case insensitive compare ... */
if
(
!
NE_strcasecmp
(
loadedfn
,
s
))
if
(
!
_strnicmp
(
loadedfn
,
s
,
-
1
))
return
hModule
;
}
return
0
;
...
...
@@ -1820,7 +1792,7 @@ static HMODULE16 NE_GetModuleByFilename( LPCSTR name )
loadedfn
--
;
}
/* case insensitive compare ... */
if
(
!
NE_strcasecmp
(
loadedfn
,
s
))
if
(
!
_strnicmp
(
loadedfn
,
s
,
-
1
))
return
hModule
;
}
/* If basename (without ext) matches the module name of a module:
...
...
@@ -1837,7 +1809,7 @@ static HMODULE16 NE_GetModuleByFilename( LPCSTR name )
if
(
pModule
->
ne_flags
&
NE_FFLAGS_WIN32
)
continue
;
name_table
=
(
BYTE
*
)
pModule
+
pModule
->
ne_restab
;
if
((
*
name_table
==
len
)
&&
!
NE_strncase
cmp
(
s
,
(
const
char
*
)
name_table
+
1
,
len
))
if
((
*
name_table
==
len
)
&&
!
_strni
cmp
(
s
,
(
const
char
*
)
name_table
+
1
,
len
))
return
hModule
;
}
...
...
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