Skip to content

Commit f302739

Browse files
author
Marius Burkard
committed
Merge branch 'stable-3.1'
2 parents 55c54a8 + dbaeb7e commit f302739

File tree

4 files changed

+18
-3
lines changed

4 files changed

+18
-3
lines changed

install/dist/lib/fedora.lib.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -502,13 +502,21 @@ public function configure_amavis() {
502502
$content = str_replace('{mysql_server_port}', $conf["mysql"]["port"], $content);
503503
$content = str_replace('{mysql_server_ip}', $conf['mysql']['ip'], $content);
504504
$content = str_replace('{hostname}', $conf['hostname'], $content);
505+
$content = str_replace('{amavis_config_dir}', $conf['amavis']['config_dir'], $content);
505506
wf($conf["amavis"]["config_dir"].'/amavisd.conf', $content);
506507
chmod($conf['amavis']['config_dir'].'/amavisd.conf', 0640);
507508

509+
if(!is_file($conf['amavis']['config_dir'].'/60-dkim')) {
510+
touch($conf['amavis']['config_dir'].'/60-dkim');
511+
chmod($conf['amavis']['config_dir'].'/60-dkim', 0640);
512+
}
513+
508514
// for CentOS 7.2 only
509515
if($dist['confid'] == 'centos72') {
510516
chmod($conf['amavis']['config_dir'].'/amavisd.conf', 0750);
511517
chgrp($conf['amavis']['config_dir'].'/amavisd.conf', 'amavis');
518+
chmod($conf['amavis']['config_dir'].'/60-dkim', 0750);
519+
chgrp($conf['amavis']['config_dir'].'/60-dkim', 'amavis');
512520
}
513521

514522

install/lib/install.lib.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ function get_distname() {
326326
$distid = 'centos53';
327327
$distbaseid = 'fedora';
328328
swriteln("Operating System: CentOS 5 or compatible\n");
329-
} elseif(stristr($content, 'CentOS Linux release 6')) {
329+
} elseif(stristr($content, 'CentOS Linux release 6') || stristr($content, 'CentOS release 6')) {
330330
$distname = 'CentOS';
331331
$distver = 'Unknown';
332332
$distid = 'centos53';

interface/lib/classes/remoting.inc.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,14 @@ protected function klientadd($formdef_file, $reseller_id, $params)
246246

247247
//* Execute the SQL query
248248
$app->db->query($sql);
249-
$insert_id = $app->db->insertID();
249+
if($app->db->errorMessage != '') {
250+
throw new SoapFault('database_error', $app->db->errorMessage . ' '.$sql);
251+
return false;
252+
}
253+
if ( isset($params['_primary_id'] ))
254+
$insert_id = $params['_primary_id'];
255+
else
256+
$insert_id = $app->db->insertID();
250257

251258

252259
//* Stop on error while executing the sql query

server/lib/classes/monitor_tools.inc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ function get_distname() {
293293
$distver = '5';
294294
$distid = 'centos53';
295295
$distbaseid = 'fedora';
296-
} elseif(stristr($content, 'CentOS Linux release 6')) {
296+
} elseif(stristr($content, 'CentOS Linux release 6') || stristr($content, 'CentOS release 6')) {
297297
$distname = 'CentOS';
298298
$distver = '6';
299299
$distid = 'centos53';

0 commit comments

Comments
 (0)