Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
John McEleney
/
mailutils
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
4fcac3a3
...
4fcac3a37d08298816245c759201045912d1dcfd
authored
2001-10-12 06:38:44 +0000
by
Alain Magloire
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Sigh commited the wrong file.
1 parent
a808517a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
10 deletions
mailbox/mbx_imap.c
mailbox/mbx_imap.c
View file @
4fcac3a
...
...
@@ -1538,16 +1538,14 @@ imap_header_read (header_t header, char *buffer, size_t buflen, off_t offset,
/* Select first. */
if
(
f_imap
->
state
==
IMAP_NO_STATE
)
{
char
*
section
=
NULL
;
int
status
=
imap_messages_count
(
m_imap
->
mailbox
,
NULL
);
if
(
status
!=
0
)
return
status
;
if
(
msg_imap
->
part
)
section
=
section_name
(
msg_imap
);
/* We strip the \r, but the offset/size on the imap server is with that
octet so add it in the offset, since it's the number of lines. */
if
(
msg_imap
->
part
)
{
char
*
section
=
section_name
(
msg_imap
);
status
=
imap_writeline
(
f_imap
,
"g%d FETCH %d BODY.PEEK[%s.MIME]<%d.%d>
\r\n
"
,
f_imap
->
seq
++
,
msg_imap
->
num
,
...
...
@@ -1555,6 +1553,12 @@ imap_header_read (header_t header, char *buffer, size_t buflen, off_t offset,
offset
+
msg_imap
->
header_lines
,
buflen
);
if
(
section
)
free
(
section
);
}
else
status
=
imap_writeline
(
f_imap
,
"g%d FETCH %d BODY.PEEK[HEADER]<%d.%d>
\r\n
"
,
f_imap
->
seq
++
,
msg_imap
->
num
,
offset
+
msg_imap
->
header_lines
,
buflen
);
CHECK_ERROR
(
f_imap
,
status
);
MAILBOX_DEBUG0
(
m_imap
->
mailbox
,
MU_DEBUG_PROT
,
f_imap
->
buffer
);
f_imap
->
state
=
IMAP_FETCH
;
...
...
@@ -1636,16 +1640,14 @@ imap_body_read (stream_t stream, char *buffer, size_t buflen, off_t offset,
/* Select first. */
if
(
f_imap
->
state
==
IMAP_NO_STATE
)
{
char
*
section
=
NULL
;
status
=
imap_messages_count
(
m_imap
->
mailbox
,
NULL
);
if
(
status
!=
0
)
return
status
;
if
(
msg_imap
->
part
)
section
=
section_name
(
msg_imap
);
/* We strip the \r, but the offset/size on the imap server is with the
octet, so add it since it's the number of lines. */
if
(
msg_imap
->
part
)
{
char
*
section
=
section_name
(
msg_imap
);
status
=
imap_writeline
(
f_imap
,
"g%d FETCH %d BODY.PEEK[%s]<%d.%d>
\r\n
"
,
f_imap
->
seq
++
,
msg_imap
->
num
,
...
...
@@ -1653,6 +1655,12 @@ imap_body_read (stream_t stream, char *buffer, size_t buflen, off_t offset,
offset
+
msg_imap
->
body_lines
,
buflen
);
if
(
section
)
free
(
section
);
}
else
status
=
imap_writeline
(
f_imap
,
"g%d FETCH %d BODY.PEEK[TEXT]<%d.%d>
\r\n
"
,
f_imap
->
seq
++
,
msg_imap
->
num
,
offset
+
msg_imap
->
body_lines
,
buflen
);
CHECK_ERROR
(
f_imap
,
status
);
MAILBOX_DEBUG0
(
m_imap
->
mailbox
,
MU_DEBUG_PROT
,
f_imap
->
buffer
);
f_imap
->
state
=
IMAP_FETCH
;
...
...
Please
register
or
sign in
to post a comment