[ic] pidfile command line argument ignored

Bill Randle billr@exgate.tek.com
Mon, 12 Feb 2001 14:54:32 -0800


This is a multi-part message in MIME format.
--------------8F29204326ECB859598CEA5E
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

I originally spotted this in minivend 4.04a and noticed it still exists
in Interchange 4.6.3.

A default value is set for $Global::PIDfile in interchange.pl and can
be overridden from the command line with the pidfile= argument.
Unfortunately, global_config() then resets it to
$Global::VendRoot/etc/$Global::ExeName.pid.

In addition, the default value for SocketFile (which is not overridable
on the command line) is set to $Global::VendRoot/etc/socket. I think
a better default would be $Global::ConfDir/socket.

A patch for both is below and was also submitted to bug database.

    -Bill
--------------8F29204326ECB859598CEA5E
Content-Type: text/plain; charset=us-ascii;
 name="Config.pm.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="Config.pm.diff"

--- Config.pm.orig	Sat Dec 30 07:17:11 2000
+++ Config.pm	Sun Feb 11 18:09:56 2001
@@ -264,8 +264,8 @@
     ['TcpHost',           undef,             'localhost 127.0.0.1'],
 	['SendMailProgram',  'executable',		$Global::SendMailLocation
 												|| '/usr/lib/sendmail'],
-	['PIDfile',     	  undef,             "$Global::VendRoot/etc/$Global::ExeName.pid"],
-	['SocketFile',     	  undef,             "$Global::VendRoot/etc/socket"],
+	['PIDfile',     	  undef,             $Global::PIDfile],
+	['SocketFile',     	  undef,             "$Global::ConfDir/socket"],
 	['SocketPerms',      'integer',          0600],
 	['HouseKeeping',     'integer',          60],
 	['Mall',	          'yesno',           'No'],

--------------8F29204326ECB859598CEA5E--