[dovecot-cvs] dovecot/src/imap imap-fetch-body-section.c,1.4,1.5

cras at procontrol.fi cras at procontrol.fi
Wed Jan 22 22:23:14 EET 2003


Update of /home/cvs/dovecot/src/imap
In directory danu:/tmp/cvs-serv19206

Modified Files:
	imap-fetch-body-section.c 
Log Message:
FETCH BODY[TEXT] was broken



Index: imap-fetch-body-section.c
===================================================================
RCS file: /home/cvs/dovecot/src/imap/imap-fetch-body-section.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- imap-fetch-body-section.c	21 Jan 2003 18:59:19 -0000	1.4
+++ imap-fetch-body-section.c	22 Jan 2003 20:23:12 -0000	1.5
@@ -84,9 +84,7 @@
 	if (stream == NULL)
 		return FALSE;
 
-	if (!fetch_header)
-		i_stream_seek(stream, hdr_size.physical_size);
-	else
+	if (fetch_header)
 		message_size_add(&body_size, &hdr_size);
 
 	str = t_strdup_printf("%s {%"PRIuUOFF_T"}\r\n",
@@ -95,7 +93,9 @@
 		return FALSE;
 
 	skip_cr = seek_partial(ctx->select_counter, mail->uid,
-			       &partial, stream, 0, body->skip);
+			       &partial, stream,
+			       fetch_header ? 0 : hdr_size.physical_size,
+			       body->skip);
 	ret = message_send(ctx->output, stream, &body_size,
 			   skip_cr, body->max_size);
 	if (ret > 0) {




More information about the dovecot-cvs mailing list