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
dec243fd
Commit
dec243fd
authored
Jan 31, 2017
by
Jacek Caban
Committed by
Alexandre Julliard
Jan 31, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
inetcomm: Don't include headers in data stream in create_sub_body.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3ccba10a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
16 deletions
+16
-16
mimeole.c
dlls/inetcomm/mimeole.c
+15
-13
mimeole.c
dlls/inetcomm/tests/mimeole.c
+1
-3
No files found.
dlls/inetcomm/mimeole.c
View file @
dec243fd
...
...
@@ -2027,19 +2027,27 @@ end:
static
body_t
*
create_sub_body
(
MimeMessage
*
msg
,
IStream
*
pStm
,
BODYOFFSETS
*
offset
,
body_t
*
parent
)
{
ULARGE_INTEGER
start
,
length
;
MimeBody
*
mime_body
;
HRESULT
hr
;
body_t
*
body
;
ULARGE_INTEGER
cur
;
LARGE_INTEGER
zero
;
LARGE_INTEGER
pos
;
pos
.
QuadPart
=
offset
->
cbHeaderStart
;
IStream_Seek
(
pStm
,
pos
,
STREAM_SEEK_SET
,
NULL
);
mime_body
=
mimebody_create
();
IMimeBody_Load
(
&
mime_body
->
IMimeBody_iface
,
pStm
);
zero
.
QuadPart
=
0
;
hr
=
IStream_Seek
(
pStm
,
zero
,
STREAM_SEEK_CUR
,
&
cur
);
offset
->
cbBodyStart
=
cur
.
u
.
LowPart
+
offset
->
cbHeaderStart
;
pos
.
QuadPart
=
0
;
hr
=
IStream_Seek
(
pStm
,
pos
,
STREAM_SEEK_CUR
,
&
start
);
offset
->
cbBodyStart
=
start
.
QuadPart
;
if
(
parent
)
MimeBody_set_offsets
(
mime_body
,
offset
);
IMimeBody_SetData
(
&
mime_body
->
IMimeBody_iface
,
IET_BINARY
,
NULL
,
NULL
,
&
IID_IStream
,
pStm
);
length
.
QuadPart
=
offset
->
cbBodyEnd
-
offset
->
cbBodyStart
;
create_sub_stream
(
pStm
,
start
,
length
,
(
IStream
**
)
&
mime_body
->
data
);
mime_body
->
data_iid
=
IID_IStream
;
body
=
new_body_entry
(
mime_body
,
msg
->
next_index
++
,
parent
);
if
(
IMimeBody_IsContentType
(
&
mime_body
->
IMimeBody_iface
,
"multipart"
,
NULL
)
==
S_OK
)
...
...
@@ -2064,14 +2072,8 @@ static body_t *create_sub_body(MimeMessage *msg, IStream *pStm, BODYOFFSETS *off
LIST_FOR_EACH_ENTRY_SAFE
(
cur
,
cursor2
,
&
offset_list
,
offset_entry_t
,
entry
)
{
body_t
*
sub_body
;
IStream
*
sub_stream
;
ULARGE_INTEGER
start
,
length
;
start
.
QuadPart
=
cur
->
offsets
.
cbHeaderStart
;
length
.
QuadPart
=
cur
->
offsets
.
cbBodyEnd
-
cur
->
offsets
.
cbHeaderStart
;
create_sub_stream
(
pStm
,
start
,
length
,
&
sub_stream
);
sub_body
=
create_sub_body
(
msg
,
sub_stream
,
&
cur
->
offsets
,
body
);
IStream_Release
(
sub_stream
);
sub_body
=
create_sub_body
(
msg
,
pStm
,
&
cur
->
offsets
,
body
);
list_add_tail
(
&
body
->
children
,
&
sub_body
->
entry
);
list_remove
(
&
cur
->
entry
);
HeapFree
(
GetProcessHeap
(),
0
,
cur
);
...
...
dlls/inetcomm/tests/mimeole.c
View file @
dec243fd
...
...
@@ -693,9 +693,7 @@ static void test_CreateMessage(void)
hr
=
IMimeBody_IsContentType
(
attachment
,
"multipart"
,
NULL
);
ok
(
hr
==
S_FALSE
,
"ret %08x
\n
"
,
hr
);
hr
=
IMimeBody_GetCurrentEncoding
(
attachment
,
&
encoding
);
ok
(
hr
==
S_OK
,
"ret %08x
\n
"
,
hr
);
todo_wine
ok
(
encoding
==
IET_7BIT
,
"ret %d
\n
"
,
encoding
);
test_current_encoding
(
attachment
,
IET_7BIT
);
prop
.
vt
=
VT_LPSTR
;
hr
=
IMimeBody_GetProp
(
attachment
,
"Content-Transfer-Encoding"
,
0
,
&
prop
);
...
...
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