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
722cb46c
Commit
722cb46c
authored
Jun 21, 2012
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Jun 21, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
windowscodecs: Fix handling of 8-byte IFD fields.
parent
aedd9271
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
metadatahandler.c
dlls/windowscodecs/metadatahandler.c
+12
-12
No files found.
dlls/windowscodecs/metadatahandler.c
View file @
722cb46c
...
...
@@ -649,7 +649,6 @@ HRESULT UnknownMetadataReader_CreateInstance(IUnknown *pUnkOuter, REFIID iid, vo
#define SWAP_ULONG(x) do { if (!native_byte_order) (x) = RtlUlongByteSwap(x); } while(0)
#define SWAP_ULONGLONG(x) do { if (!native_byte_order) (x) = RtlUlonglongByteSwap(x); } while(0)
#include "pshpack2.h"
struct
IFD_entry
{
SHORT
id
;
...
...
@@ -658,13 +657,6 @@ struct IFD_entry
LONG
value
;
};
struct
IFD_rational
{
LONG
numerator
;
LONG
denominator
;
};
#include "poppack.h"
#define IFD_BYTE 1
#define IFD_ASCII 2
#define IFD_SHORT 3
...
...
@@ -840,16 +832,24 @@ static HRESULT load_IFD_entry(IStream *input, const struct IFD_entry *entry,
case
IFD_DOUBLE
:
if
(
count
==
1
)
{
struct
IFD_rational
rationa
l
;
ULONGLONG
ul
l
;
pos
.
QuadPart
=
value
;
hr
=
IStream_Seek
(
input
,
pos
,
SEEK_SET
,
NULL
);
if
(
FAILED
(
hr
))
return
hr
;
hr
=
IStream_Read
(
input
,
&
rational
,
sizeof
(
rationa
l
),
NULL
);
hr
=
IStream_Read
(
input
,
&
ull
,
sizeof
(
ul
l
),
NULL
);
if
(
FAILED
(
hr
))
return
hr
;
item
->
value
.
u
.
uhVal
.
QuadPart
=
((
LONGLONG
)
rational
.
denominator
<<
32
)
|
rational
.
numerator
;
SWAP_ULONGLONG
(
item
->
value
.
u
.
uhVal
.
QuadPart
);
item
->
value
.
u
.
uhVal
.
QuadPart
=
ull
;
if
(
type
==
IFD_DOUBLE
)
SWAP_ULONGLONG
(
item
->
value
.
u
.
uhVal
.
QuadPart
);
else
{
SWAP_ULONG
(
item
->
value
.
u
.
uhVal
.
u
.
LowPart
);
SWAP_ULONG
(
item
->
value
.
u
.
uhVal
.
u
.
HighPart
);
}
break
;
}
FIXME
(
"loading multiple rational fields is not implemented
\n
"
);
...
...
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