Merging in various fixes from trunk.

upgrade.php:
- change domain.quota, domain.maxquota and mailbox.quota to bigint in PostgreSQL

setup.php:
- strict boolean check for $CONF['configured'] - similar to the check in login.php


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/branches/postfixadmin-2.3@969 a1433add-5e2c-0410-b055-b7f2511e0802
postfixadmin-2.3
Christian Boltz 14 years ago
parent 2d48df75c1
commit c2071fc7a0

@ -21,6 +21,8 @@ Version 2.3.3 - 2011/**/** - SVN r*** (postfixadmin-2.3 branch)
- functions.inc.php: better error messages when database functions are missing
- create domain: fixed typo in variable name that broke the default value for
default aliases
- postgres: changed mailbox.quota, domain.quota and domain.maxquota fields
to bigint to allow mailboxes >4 GB (run setup.php to upgrade your database)
- vacation.pl logged literal $variable instead of the variable content at two
places
- POSTFIX_CONF.txt: fixed filename for quota map

@ -125,7 +125,7 @@ if ($file_config == 1)
require($incpath.'/config.inc.php');
if(isset($CONF['configured'])) {
if($CONF['configured'] == TRUE) {
if($CONF['configured'] === TRUE) {
print "<li>Checking \$CONF['configured'] - OK\n";
} else {
print "<li><b>Warning: \$CONF['configured'] is 'false'.<br>\n";

@ -108,7 +108,7 @@ _do_upgrade($version);
function _do_upgrade($current_version) {
global $CONF;
# $target_version = preg_replace('/[^0-9]/', '', '$Revision$');
$target_version = 739; # hardcoded target version for 2.3 branch - increase (by one) if database changes in the branch are necessary
$target_version = 740; # hardcoded target version for 2.3 branch - increase (by one) if database changes in the branch are necessary
if ($current_version >= $target_version) {
# already up to date
@ -1182,3 +1182,13 @@ function upgrade_730_pgsql() {
FOR EACH ROW EXECUTE PROCEDURE merge_quota2();
");
}
function upgrade_740_pgsql() { # upgrade_968_pgsql() in SVN trunk
# pgsql counterpart for upgrade_169_mysql() - allow really big quota
$table_domain = table_by_key ('domain');
$table_mailbox = table_by_key('mailbox');
db_query_parsed("ALTER TABLE $table_domain ALTER COLUMN quota type bigint");
db_query_parsed("ALTER TABLE $table_domain ALTER COLUMN maxquota type bigint");
db_query_parsed("ALTER TABLE $table_mailbox ALTER COLUMN quota type bigint");
}

Loading…
Cancel
Save