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
361e3b1a
Commit
361e3b1a
authored
Nov 20, 2011
by
Francois Gouget
Committed by
Alexandre Julliard
Nov 21, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
windowscodecs/tests: Fix compilation on systems that don't support nameless unions.
parent
3315918e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
11 deletions
+11
-11
metadata.c
dlls/windowscodecs/tests/metadata.c
+11
-11
No files found.
dlls/windowscodecs/tests/metadata.c
View file @
361e3b1a
...
@@ -31,9 +31,9 @@
...
@@ -31,9 +31,9 @@
#define expect_blob(propvar, data, length) do { \
#define expect_blob(propvar, data, length) do { \
ok((propvar).vt == VT_BLOB, "unexpected vt: %i\n", (propvar).vt); \
ok((propvar).vt == VT_BLOB, "unexpected vt: %i\n", (propvar).vt); \
if ((propvar).vt == VT_BLOB) { \
if ((propvar).vt == VT_BLOB) { \
ok(
(propvar).blob.cbSize == (length), "expected size %i, got %i\n", (length),
(propvar).blob.cbSize); \
ok(
U(propvar).blob.cbSize == (length), "expected size %i, got %i\n", (length), U
(propvar).blob.cbSize); \
if ((propvar).blob.cbSize == (length)) { \
if (
U
(propvar).blob.cbSize == (length)) { \
ok(!memcmp((propvar).blob.pBlobData, (data), (length)), "unexpected data\n"); \
ok(!memcmp(
U
(propvar).blob.pBlobData, (data), (length)), "unexpected data\n"); \
} \
} \
} \
} \
} while (0)
} while (0)
...
@@ -204,9 +204,9 @@ static void test_metadata_tEXt(void)
...
@@ -204,9 +204,9 @@ static void test_metadata_tEXt(void)
{
{
ok
(
schema
.
vt
==
VT_EMPTY
,
"unexpected vt: %i
\n
"
,
schema
.
vt
);
ok
(
schema
.
vt
==
VT_EMPTY
,
"unexpected vt: %i
\n
"
,
schema
.
vt
);
ok
(
id
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
id
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
!
strcmp
(
id
.
pszVal
,
"winetest"
),
"unexpected id: %s
\n
"
,
id
.
pszVal
);
ok
(
!
strcmp
(
U
(
id
).
pszVal
,
"winetest"
),
"unexpected id: %s
\n
"
,
U
(
id
)
.
pszVal
);
ok
(
value
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
value
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
!
strcmp
(
value
.
pszVal
,
"value"
),
"unexpected value: %s
\n
"
,
id
.
pszVal
);
ok
(
!
strcmp
(
U
(
value
).
pszVal
,
"value"
),
"unexpected value: %s
\n
"
,
U
(
id
)
.
pszVal
);
PropVariantClear
(
&
schema
);
PropVariantClear
(
&
schema
);
PropVariantClear
(
&
id
);
PropVariantClear
(
&
id
);
...
@@ -228,8 +228,8 @@ static void test_metadata_tEXt(void)
...
@@ -228,8 +228,8 @@ static void test_metadata_tEXt(void)
ok
(
hr
==
E_INVALIDARG
,
"GetMetadataFormat failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
E_INVALIDARG
,
"GetMetadataFormat failed, hr=%x
\n
"
,
hr
);
id
.
vt
=
VT_LPSTR
;
id
.
vt
=
VT_LPSTR
;
id
.
pszVal
=
CoTaskMemAlloc
(
strlen
(
"winetest"
)
+
1
);
U
(
id
)
.
pszVal
=
CoTaskMemAlloc
(
strlen
(
"winetest"
)
+
1
);
strcpy
(
id
.
pszVal
,
"winetest"
);
strcpy
(
U
(
id
)
.
pszVal
,
"winetest"
);
hr
=
IWICMetadataReader_GetValue
(
reader
,
NULL
,
&
id
,
NULL
);
hr
=
IWICMetadataReader_GetValue
(
reader
,
NULL
,
&
id
,
NULL
);
ok
(
hr
==
S_OK
,
"GetValue failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"GetValue failed, hr=%x
\n
"
,
hr
);
...
@@ -240,10 +240,10 @@ static void test_metadata_tEXt(void)
...
@@ -240,10 +240,10 @@ static void test_metadata_tEXt(void)
hr
=
IWICMetadataReader_GetValue
(
reader
,
&
schema
,
&
id
,
&
value
);
hr
=
IWICMetadataReader_GetValue
(
reader
,
&
schema
,
&
id
,
&
value
);
ok
(
hr
==
S_OK
,
"GetValue failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"GetValue failed, hr=%x
\n
"
,
hr
);
ok
(
value
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
value
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
!
strcmp
(
value
.
pszVal
,
"value"
),
"unexpected value: %s
\n
"
,
id
.
pszVal
);
ok
(
!
strcmp
(
U
(
value
).
pszVal
,
"value"
),
"unexpected value: %s
\n
"
,
U
(
id
)
.
pszVal
);
PropVariantClear
(
&
value
);
PropVariantClear
(
&
value
);
strcpy
(
id
.
pszVal
,
"test"
);
strcpy
(
U
(
id
)
.
pszVal
,
"test"
);
hr
=
IWICMetadataReader_GetValue
(
reader
,
&
schema
,
&
id
,
&
value
);
hr
=
IWICMetadataReader_GetValue
(
reader
,
&
schema
,
&
id
,
&
value
);
ok
(
hr
==
WINCODEC_ERR_PROPERTYNOTFOUND
,
"GetValue failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
WINCODEC_ERR_PROPERTYNOTFOUND
,
"GetValue failed, hr=%x
\n
"
,
hr
);
...
@@ -260,13 +260,13 @@ static void test_metadata_tEXt(void)
...
@@ -260,13 +260,13 @@ static void test_metadata_tEXt(void)
hr
=
IWICMetadataReader_GetValueByIndex
(
reader
,
0
,
NULL
,
&
id
,
NULL
);
hr
=
IWICMetadataReader_GetValueByIndex
(
reader
,
0
,
NULL
,
&
id
,
NULL
);
ok
(
hr
==
S_OK
,
"GetValueByIndex failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"GetValueByIndex failed, hr=%x
\n
"
,
hr
);
ok
(
id
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
id
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
!
strcmp
(
id
.
pszVal
,
"winetest"
),
"unexpected id: %s
\n
"
,
id
.
pszVal
);
ok
(
!
strcmp
(
U
(
id
).
pszVal
,
"winetest"
),
"unexpected id: %s
\n
"
,
U
(
id
)
.
pszVal
);
PropVariantClear
(
&
id
);
PropVariantClear
(
&
id
);
hr
=
IWICMetadataReader_GetValueByIndex
(
reader
,
0
,
NULL
,
NULL
,
&
value
);
hr
=
IWICMetadataReader_GetValueByIndex
(
reader
,
0
,
NULL
,
NULL
,
&
value
);
ok
(
hr
==
S_OK
,
"GetValueByIndex failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"GetValueByIndex failed, hr=%x
\n
"
,
hr
);
ok
(
value
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
value
.
vt
==
VT_LPSTR
,
"unexpected vt: %i
\n
"
,
id
.
vt
);
ok
(
!
strcmp
(
value
.
pszVal
,
"value"
),
"unexpected value: %s
\n
"
,
id
.
pszVal
);
ok
(
!
strcmp
(
U
(
value
).
pszVal
,
"value"
),
"unexpected value: %s
\n
"
,
U
(
id
)
.
pszVal
);
PropVariantClear
(
&
value
);
PropVariantClear
(
&
value
);
hr
=
IWICMetadataReader_GetValueByIndex
(
reader
,
1
,
NULL
,
NULL
,
NULL
);
hr
=
IWICMetadataReader_GetValueByIndex
(
reader
,
1
,
NULL
,
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