[sork] Quota pb in Accounts

Ludovic Ishiomin lishiomin at free.fr
Tue Jan 4 10:29:22 PST 2005


Hello and happy new year,

I think there is a bug in the quota parsing.
Please find the patch attached, from the CVS checked today.

Have you got some tips to implement quotas for other mail repositories ?
For example, in my configuration, (RH AS 3.0 with LVM), I have quota enabled on
/dev/Data/Mail mounted on /var/spool/mail (INBOX only) and
/dev/Data/Home mounted on /home (other mailboxes made with imp).
Just parse the result of the quota command ?
What would be the best way to display the different repositories, and the mailboxes associated with ?

Thanks
-------------- next part --------------
--- accounts/lib/Driver/localhostbad.php	2005-01-04 18:08:29.000000000 +0100
+++ accounts/lib/Driver/localhost.php	2005-01-04 17:59:01.000000000 +0100
@@ -144,7 +144,7 @@
                $quota_data[0] .= $quota_data[1];
            }
            // Now parse out the quota info and return it.
-           $quota = preg_split('/[[:blank:]]+/', trim($quota_data[0]));
+           $quota = split('[[:blank:]]+', trim($quota_data[0]));
            return array('used' => $quota[1] * 1024, 'limit' => $quota[2] * 1024);
         }
         return false;


More information about the sork mailing list