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
4c90bbd6
Commit
4c90bbd6
authored
Apr 24, 2007
by
Paul Vriens
Committed by
Alexandre Julliard
Apr 24, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32/tests: Use A-version for registry functions.
parent
5e1ca160
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
13 deletions
+14
-13
oid.c
dlls/crypt32/tests/oid.c
+14
-13
No files found.
dlls/crypt32/tests/oid.c
View file @
4c90bbd6
...
...
@@ -84,6 +84,9 @@ static const struct OIDToAlgID algIDToOID[] = {
{
szOID_OIWSEC_sha1
,
CALG_SHA
},
};
static
const
WCHAR
bogusDll
[]
=
{
'b'
,
'o'
,
'g'
,
'u'
,
's'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
static
const
WCHAR
bogus2Dll
[]
=
{
'b'
,
'o'
,
'g'
,
'u'
,
's'
,
'2'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
static
void
testOIDToAlgID
(
void
)
{
int
i
;
...
...
@@ -264,7 +267,6 @@ static void test_installOIDFunctionAddress(void)
static
void
test_registerOIDFunction
(
void
)
{
static
const
WCHAR
bogusDll
[]
=
{
'b'
,
'o'
,
'g'
,
'u'
,
's'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
BOOL
ret
;
/* oddly, this succeeds under WinXP; the function name key is merely
...
...
@@ -315,9 +317,6 @@ static void test_registerOIDFunction(void)
ok
(
ret
,
"CryptUnregisterOIDFunction failed: %d
\n
"
,
GetLastError
());
}
static
const
WCHAR
bogusDll
[]
=
{
'b'
,
'o'
,
'g'
,
'u'
,
's'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
static
const
WCHAR
bogus2Dll
[]
=
{
'b'
,
'o'
,
'g'
,
'u'
,
's'
,
'2'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
static
void
test_registerDefaultOIDFunction
(
void
)
{
static
const
char
fmt
[]
=
...
...
@@ -354,24 +353,26 @@ static void test_registerDefaultOIDFunction(void)
ok
(
ret
,
"CryptRegisterDefaultOIDFunction failed: %08x
\n
"
,
GetLastError
());
sprintf
(
buf
,
fmt
,
0
,
func
);
rc
=
RegOpenKeyA
(
HKEY_LOCAL_MACHINE
,
buf
,
&
key
);
ok
(
rc
==
0
,
"Expected key to exist, RegOpenKey
W
failed: %ld
\n
"
,
rc
);
ok
(
rc
==
0
,
"Expected key to exist, RegOpenKey
A
failed: %ld
\n
"
,
rc
);
if
(
rc
==
0
)
{
static
const
WCHAR
dllW
[]
=
{
'D'
,
'l'
,
'l'
,
0
};
WCHAR
dllBuf
[
MAX_PATH
];
static
const
CHAR
dllA
[]
=
"Dll"
;
static
const
CHAR
bogusDll_A
[]
=
"bogus.dll"
;
static
const
CHAR
bogus2Dll_A
[]
=
"bogus2.dll"
;
CHAR
dllBuf
[
MAX_PATH
];
DWORD
type
,
size
;
LP
W
STR
ptr
;
LPSTR
ptr
;
size
=
sizeof
(
dllBuf
)
/
sizeof
(
dllBuf
[
0
]);
rc
=
RegQueryValueEx
W
(
key
,
dllW
,
NULL
,
&
type
,
(
LPBYTE
)
dllBuf
,
&
size
);
rc
=
RegQueryValueEx
A
(
key
,
dllA
,
NULL
,
&
type
,
(
LPBYTE
)
dllBuf
,
&
size
);
ok
(
rc
==
0
,
"Expected Dll value to exist, RegQueryValueEx
W
failed: %ld
\n
"
,
rc
);
"Expected Dll value to exist, RegQueryValueEx
A
failed: %ld
\n
"
,
rc
);
ok
(
type
==
REG_MULTI_SZ
,
"Expected type REG_MULTI_SZ, got %d
\n
"
,
type
);
/* bogusDll was registered first, so that should be first */
ptr
=
dllBuf
;
ok
(
!
lstrcmpi
W
(
ptr
,
bogusDll
),
"Unexpected dll
\n
"
);
ptr
+=
lstrlen
W
(
ptr
)
+
1
;
ok
(
!
lstrcmpi
W
(
ptr
,
bogus2Dll
),
"Unexpected dll
\n
"
);
ok
(
!
lstrcmpi
A
(
ptr
,
bogusDll_A
),
"Unexpected dll
\n
"
);
ptr
+=
lstrlen
A
(
ptr
)
+
1
;
ok
(
!
lstrcmpi
A
(
ptr
,
bogus2Dll_A
),
"Unexpected dll
\n
"
);
RegCloseKey
(
key
);
}
/* Unregister both of them */
...
...
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