

![]() | Start a set with this search |
![]() | Include this search in one of my sets |
![]() | Exclude this search from one of my sets |
![]() | Permalink to these results Paste this link in email or IM: |
| Atom feed for tracking future search results Paste this URL into your reader: |
1 message in net.sourceforge.lists.courier-sqwebmail[sqwebmail] Problem with size types u...| From | Sent On | Attachments |
|---|---|---|
| Cyril Bellot | Jun 12, 2009 2:32 am | .patch |

![]() | Permalink for this message Paste this link in email or IM: |
![]() | Permalink for this thread Paste this link in email or IM: |
| Atom feed for this thread Paste this URL into your reader: |
| Subject: | [sqwebmail] Problem with size types used in maildir.c | Actions... |
|---|---|---|
| From: | Cyril Bellot (cb...@accelance.fr) | |
| Date: | Jun 12, 2009 2:32:26 am | |
| List: | net.sourceforge.lists.courier-sqwebmail | |
| Attachments: | ||
(repost - previous mail fall and died in moderation)
Hello,
I have found a problem in maildirsize handling in sqwebmail. Setup: Sqwebmail 5.3.1 on FreeBSD 7.2
# cat maildirsize 52428800S 22997695 29 1172 1 1768051 1 1768051 1 1768051 1 1768049 1 1768050 1
After deleting a message (size=1768051) using sqwebmail I have an invalid size inserted:
# cat maildirsize 52428800S 44215475 42 4293199246 -1
Invalid types in maildir.c seem to be used to call maildir_quota_deleted (long versus required off_t)
I have attached a patch to correct this. It works fine here.
Regards
-- Cyril Bellot
--- sqwebmail-5.3.1/sqwebmail/maildir.c.orig 2009-06-09 16:11:37.000000000 +0200 +++ sqwebmail-5.3.1/sqwebmail/maildir.c 2009-06-09 16:14:28.000000000 +0200 @@ -799,7 +799,7 @@
if (filesize > 0) maildir_quota_deleted(".", - -(long)filesize, + -(off_t)filesize, -1); } free(d); @@ -890,7 +890,7 @@ {
if (!from_shared) - maildir_quota_deleted(".", -filesize, -1); + maildir_quota_deleted(".", -(off_t)filesize, -1); } else if (!dest_shared && maildirquota_countfolder(destdir) && (from_shared || !maildirquota_countfolder(fromdir)) @@ -1214,7 +1214,7 @@
if (filesize > 0) maildir_quota_deleted(".", - -(long)filesize, + -(off_t)filesize, -1); }
@@ -1425,7 +1425,7 @@
if (filesize > 0) maildir_quota_deleted(".", - -(long)filesize, + -(off_t)filesize, -1); }
@@ -2895,7 +2895,7 @@ { if (isok < 0) /* Force it */ { - maildir_quota_deleted(".", (long) + maildir_quota_deleted(".", (off_t) (stat_buf.st_size -prevsize), prevsize == 0 @@ -2910,7 +2910,7 @@ } else if (prevsize != stat_buf.st_size) { - maildir_quota_deleted(".", (long) + maildir_quota_deleted(".", (off_t) (stat_buf.st_size-prevsize), prevsize == 0 ? 1:0); }
------------------------------------------------------------------------------ Crystal Reports - New Free Runtime and 30 Day Trial Check out the new simplified licensing option that enables unlimited royalty-free distribution of the report engine for externally facing server and web deployment. http://p.sf.net/sfu/businessobjects
_______________________________________________ Courier-sqwebmail mailing list Cour...@lists.sourceforge.net Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-sqwebmail








.patch