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
18b5366c
Commit
18b5366c
authored
Jan 06, 2009
by
Hans Leidekker
Committed by
Alexandre Julliard
Jan 06, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
setupapi: Implement StringTableLookUpStringEx.
parent
8a976a7d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
21 deletions
+28
-21
stringtable.c
dlls/setupapi/stringtable.c
+28
-21
No files found.
dlls/setupapi/stringtable.c
View file @
18b5366c
...
...
@@ -446,35 +446,40 @@ StringTableGetExtraData(HSTRING_TABLE hStringTable,
/**************************************************************************
* StringTableLookUpString [SETUPAPI.@]
* StringTableLookUpString
Ex
[SETUPAPI.@]
*
* Searches a string table for a given string.
* Searches a string table
and extra data
for a given string.
*
* PARAMS
* hStringTable [I] Handle to the string table
* lpString [I] String to be searched for
* dwFlags [I] Flags
* 1: case sensitive compare
* lpExtraData [O] Pointer to the buffer that receives the extra data
* lpReserved [I/O] Unused
*
* RETURNS
* Success: String ID
* Failure: -1
*/
DWORD
WINAPI
StringTableLookUpString
(
HSTRING_TABLE
hStringTable
,
LPWSTR
lpString
,
DWORD
dwFlags
)
StringTableLookUpStringEx
(
HSTRING_TABLE
hStringTable
,
LPWSTR
lpString
,
DWORD
dwFlags
,
LPVOID
lpExtraData
,
LPDWORD
lpReserved
)
{
PSTRING_TABLE
pStringTable
;
DWORD
i
;
TRACE
(
"%p %s %x
\n
"
,
hStringTable
,
debugstr_w
(
lpString
),
dwFlags
);
TRACE
(
"%p %s %x %p, %p
\n
"
,
hStringTable
,
debugstr_w
(
lpString
),
dwFlags
,
lpExtraData
,
lpReserved
);
pStringTable
=
(
PSTRING_TABLE
)
hStringTable
;
if
(
pStringTable
==
NULL
)
{
ERR
(
"Invalid hStringTable!
\n
"
);
return
(
DWORD
)
-
1
;
return
~
0u
;
}
/* Search for existing string in the string table */
...
...
@@ -485,46 +490,48 @@ StringTableLookUpString(HSTRING_TABLE hStringTable,
if
(
dwFlags
&
1
)
{
if
(
!
lstrcmpW
(
pStringTable
->
pSlots
[
i
].
pString
,
lpString
))
{
if
(
lpExtraData
)
memcpy
(
lpExtraData
,
pStringTable
->
pSlots
[
i
].
pData
,
pStringTable
->
pSlots
[
i
].
dwSize
);
return
i
+
1
;
}
}
else
{
if
(
!
lstrcmpiW
(
pStringTable
->
pSlots
[
i
].
pString
,
lpString
))
{
if
(
lpExtraData
)
memcpy
(
lpExtraData
,
pStringTable
->
pSlots
[
i
].
pData
,
pStringTable
->
pSlots
[
i
].
dwSize
);
return
i
+
1
;
}
}
}
}
return
(
DWORD
)
-
1
;
return
~
0u
;
}
/**************************************************************************
* StringTableLookUpString
Ex
[SETUPAPI.@]
* StringTableLookUpString [SETUPAPI.@]
*
* Searches a string table
and extra data
for a given string.
* Searches a string table for a given string.
*
* PARAMS
* hStringTable [I] Handle to the string table
* lpString [I] String to be searched for
* dwFlags [I] Flags
* 1: case sensitive compare
* lpExtraData [O] Pointer to the buffer that receives the extra data
* lpReserved [I/O] Unused
*
* RETURNS
* Success: String ID
* Failure:
-1
* Failure:
~0u
*/
DWORD
WINAPI
StringTableLookUpStringEx
(
HSTRING_TABLE
hStringTable
,
LPWSTR
lpString
,
DWORD
dwFlags
,
LPVOID
lpExtraData
,
LPDWORD
lpReserved
)
StringTableLookUpString
(
HSTRING_TABLE
hStringTable
,
LPWSTR
lpString
,
DWORD
dwFlags
)
{
FIXME
(
"
\n
"
);
return
(
DWORD
)
-
1
;
return
StringTableLookUpStringEx
(
hStringTable
,
lpString
,
dwFlags
,
NULL
,
NULL
);
}
...
...
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