? ldirectord.1.58-1.59.patch ? ldirectord.1.59-1.60.patch ? leak.patch Index: ldirectord =================================================================== RCS file: /home/cvs/linux-ha/linux-ha/ldirectord/ldirectord,v retrieving revision 1.59 retrieving revision 1.60 diff -r1.59 -r1.60 4c4 < my($VERSION)=(qw$Id: ldirectord,v 1.59 2002/10/17 00:53:29 horms Exp $)[2]; --- > my($VERSION)=(qw$Id: ldirectord,v 1.60 2002/11/19 11:38:15 horms Exp $)[2]; 361a362,370 > # There is a memory leak in perl's socket code when > # the default IO layer is used. So use "perlio" unless > # something else has been explicitly set. > # http://archive.develooper.com/perl5-porters@xxxxxxxx/msg85468.html > unless(defined($ENV{'PERLIO'})) { > $ENV{'PERLIO'} = "perlio"; > exec_wrapper($0, @OLD_ARGV); > } > 2168c2177 < # Wrapper arround system command to log errors --- > # Wrapper around system() to log errors 2170,2171c2179,2181 < # post: system is called and if it returns non-zero a failure message is logged < # return: none --- > # post: system() is called and if it returns non-zero a failure > # message is logged > # return: return value of system() 2175a2186,2188 > > my $status; > 2177c2190,2219 < system(@args) == 0 or &ld_log("system(@args) failed"); --- > $status = system(@args); > if($status != 0) { > &ld_log("system(@args) failed"); > } > > return($status) > } > > > # exec_wrapper > # Wrapper around exec() to log errors > # pre: LIST: arguments to pass to exec() > # post: exec() is called and if it returns non-zero a failure > # message is logged > # return: return value of exec() on failure > # does not return on success > > sub exec_wrapper > { > my (@args)=(@_); > > my $status; > > &ld_log("Running exec(@args)") if $DEBUG>2; > $status = exec(@args); > if($status != 0) { > &ld_log("exec(@args) failed"); > } > > return($status)