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
780deecf
Commit
780deecf
authored
Feb 17, 2004
by
Robert Shearman
Committed by
Alexandre Julliard
Feb 17, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Add IntlStrEqWorkerA/W.
- StrCmp tests.
parent
524cad74
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
46 additions
and
4 deletions
+46
-4
shlwapi.spec
dlls/shlwapi/shlwapi.spec
+2
-2
string.c
dlls/shlwapi/string.c
+2
-2
string.c
dlls/shlwapi/tests/string.c
+42
-0
No files found.
dlls/shlwapi/shlwapi.spec
View file @
780deecf
...
...
@@ -561,8 +561,8 @@
@ stdcall DllGetVersion (ptr) SHLWAPI_DllGetVersion
@ stdcall GetMenuPosFromID(ptr long)
@ stdcall HashData (ptr long ptr long)
@ st
ub IntlStrEqWorker
A
@ st
ub IntlStrEqWorker
W
@ st
dcall IntlStrEqWorkerA(long str str long) StrIsIntlEqual
A
@ st
dcall IntlStrEqWorkerW(long wstr wstr long) StrIsIntlEqual
W
@ stdcall PathAddBackslashA (str)
@ stdcall PathAddBackslashW (wstr)
@ stdcall PathAddExtensionA (str str)
...
...
dlls/shlwapi/string.c
View file @
780deecf
...
...
@@ -671,13 +671,13 @@ LPWSTR WINAPI StrStrIW(LPCWSTR lpszStr, LPCWSTR lpszSearch)
/*************************************************************************
* StrToIntA [SHLWAPI.@]
*
* Read a
n
integer from a string.
* Read a
signed
integer from a string.
*
* PARAMS
* lpszStr [I] String to read integer from
*
* RETURNS
* The integer value represented by the string, or 0 if no integer is
* The
signed
integer value represented by the string, or 0 if no integer is
* present.
*
* NOTES
...
...
dlls/shlwapi/tests/string.c
View file @
780deecf
...
...
@@ -546,6 +546,46 @@ void test_StrFromTimeIntervalA(void)
}
}
void
test_StrCmpA
(
void
)
{
static
const
char
str1
[]
=
{
'a'
,
'b'
,
'c'
,
'd'
,
'e'
,
'f'
};
static
const
char
str2
[]
=
{
'a'
,
'B'
,
'c'
,
'd'
,
'e'
,
'f'
};
ok
(
0
!=
StrCmpNA
(
str1
,
str2
,
6
),
"StrCmpNA is case-insensitive
\n
"
);
ok
(
0
==
StrCmpNIA
(
str1
,
str2
,
6
),
"StrCmpNIA is case-sensitive
\n
"
);
ok
(
!
ChrCmpIA
(
'a'
,
'a'
),
"ChrCmpIA doesn't work at all!
\n
"
);
ok
(
!
ChrCmpIA
(
'b'
,
'B'
),
"ChrCmpIA is not case-insensitive
\n
"
);
ok
(
ChrCmpIA
(
'a'
,
'z'
),
"ChrCmpIA believes that a == z!
\n
"
);
todo_wine
{
ok
(
StrIsIntlEqualA
(
FALSE
,
str1
,
str2
,
5
),
"StrIsIntlEqualA(FALSE,...) isn't case-insensitive
\n
"
);
}
ok
(
!
StrIsIntlEqualA
(
TRUE
,
str1
,
str2
,
5
),
"StrIsIntlEqualA(TRUE,...) isn't case-sensitive
\n
"
);
todo_wine
{
ok
(
IntlStrEqWorkerA
(
FALSE
,
str1
,
str2
,
5
),
"IntlStrEqWorkerA(FALSE,...) isn't case-insensitive
\n
"
);
}
ok
(
!
IntlStrEqWorkerA
(
TRUE
,
str1
,
str2
,
5
),
"IntlStrEqWorkerA(TRUE,...) isn't case-sensitive
\n
"
);
}
void
test_StrCmpW
(
void
)
{
static
const
WCHAR
str1
[]
=
{
'a'
,
'b'
,
'c'
,
'd'
,
'e'
,
'f'
};
static
const
WCHAR
str2
[]
=
{
'a'
,
'B'
,
'c'
,
'd'
,
'e'
,
'f'
};
ok
(
0
!=
StrCmpNW
(
str1
,
str2
,
5
),
"StrCmpNW is case-insensitive
\n
"
);
ok
(
0
==
StrCmpNIW
(
str1
,
str2
,
5
),
"StrCmpNIW is case-sensitive
\n
"
);
ok
(
!
ChrCmpIW
(
'a'
,
'a'
),
"ChrCmpIW doesn't work at all!
\n
"
);
ok
(
!
ChrCmpIW
(
'b'
,
'B'
),
"ChrCmpIW is not case-insensitive
\n
"
);
ok
(
ChrCmpIW
(
'a'
,
'z'
),
"ChrCmpIW believes that a == z!
\n
"
);
ok
(
StrIsIntlEqualW
(
FALSE
,
str1
,
str2
,
5
),
"StrIsIntlEqualW(FALSE,...) isn't case-insensitive
\n
"
);
ok
(
!
StrIsIntlEqualW
(
TRUE
,
str1
,
str2
,
5
),
"StrIsIntlEqualW(TRUE,...) isn't case-sensitive
\n
"
);
ok
(
IntlStrEqWorkerW
(
FALSE
,
str1
,
str2
,
5
),
"IntlStrEqWorkerW(FALSE,...) isn't case-insensitive
\n
"
);
ok
(
!
IntlStrEqWorkerW
(
TRUE
,
str1
,
str2
,
5
),
"IntlStrEqWorkerW(TRUE,...) isn't case-sensitive
\n
"
);
}
static
WCHAR
*
CoDupStrW
(
const
char
*
src
)
{
INT
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
src
,
-
1
,
NULL
,
0
);
...
...
@@ -611,5 +651,7 @@ START_TEST(string)
test_StrFormatKBSizeA
();
test_StrFormatKBSizeW
();
test_StrFromTimeIntervalA
();
test_StrCmpA
();
test_StrCmpW
();
test_StrRetToBSTR
();
}
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