diff src/lib-storage/index/dbox-common/dbox-file.c @ 10765:19df4309e389 HEAD

lib-storage: Added support for plugins to specify message's physical size when saving. Changed dbox to save this value to metadata, and use when present.
author Timo Sirainen <tss@iki.fi>
date Fri, 19 Feb 2010 07:15:46 +0200
parents 9c68c8d42ff2
children 638c4ea4a9ce
line wrap: on
line diff
--- a/src/lib-storage/index/dbox-common/dbox-file.c	Fri Feb 19 07:14:41 2010 +0200
+++ b/src/lib-storage/index/dbox-common/dbox-file.c	Fri Feb 19 07:15:46 2010 +0200
@@ -310,7 +310,6 @@
 }
 
 int dbox_file_get_mail_stream(struct dbox_file *file, uoff_t offset,
-			      uoff_t *physical_size_r,
 			      struct istream **stream_r)
 {
 	uoff_t size;
@@ -334,7 +333,6 @@
 		*stream_r = i_stream_create_limit(file->input,
 						  file->cur_physical_size);
 	}
-	*physical_size_r = file->cur_physical_size;
 	return 1;
 }
 
@@ -366,7 +364,7 @@
 
 int dbox_file_seek_next(struct dbox_file *file, uoff_t *offset_r, bool *last_r)
 {
-	uoff_t offset, size;
+	uoff_t offset;
 	int ret;
 
 	i_assert(file->input != NULL);
@@ -391,7 +389,7 @@
 	}
 	*last_r = FALSE;
 
-	ret = dbox_file_get_mail_stream(file, offset, &size, NULL);
+	ret = dbox_file_get_mail_stream(file, offset, NULL);
 	if (*offset_r == 0)
 		*offset_r = file->file_header_size;
 	return ret;