pf-tools commit: r811 [ccaillet-guest] - in /branches/next-gen/lib/PFTools: Conf.pm Utils.pm VCS.pm

parmelan-guest at users.alioth.debian.org parmelan-guest at users.alioth.debian.org
Fri Aug 6 12:28:30 UTC 2010


Author: ccaillet-guest
Date: Fri Aug  6 12:28:28 2010
New Revision: 811

URL: http://svn.debian.org/wsvn/pf-tools/?sc=1&rev=811
Log:
Fix: renaming variable and removing useless parameter

Modified:
    branches/next-gen/lib/PFTools/Conf.pm
    branches/next-gen/lib/PFTools/Utils.pm
    branches/next-gen/lib/PFTools/VCS.pm

Modified: branches/next-gen/lib/PFTools/Conf.pm
URL: http://svn.debian.org/wsvn/pf-tools/branches/next-gen/lib/PFTools/Conf.pm?rev=811&op=diff
==============================================================================
--- branches/next-gen/lib/PFTools/Conf.pm (original)
+++ branches/next-gen/lib/PFTools/Conf.pm Fri Aug  6 12:28:28 2010
@@ -320,7 +320,7 @@
 $PF_CONFIG->{'vcs'} = {
 	'type'		=> 'cvs',
 	'user'		=> 'cvsguest',
-	'method'	=> 'rsh'
+	'method'	=> 'rsh',
 	'rsh'		=> '/usr/local/sbin/cvs_rsh',
 	'server'	=> 'cvs.private',
 	'cvsroot'	=> '/var/lib/cvs/repository',

Modified: branches/next-gen/lib/PFTools/Utils.pm
URL: http://svn.debian.org/wsvn/pf-tools/branches/next-gen/lib/PFTools/Utils.pm?rev=811&op=diff
==============================================================================
--- branches/next-gen/lib/PFTools/Utils.pm (original)
+++ branches/next-gen/lib/PFTools/Utils.pm Fri Aug  6 12:28:28 2010
@@ -940,7 +940,7 @@
 	my ( $hostname, $site, $options, $global_config, $pf_config ) = @_;
 	my $errorcount = 0;
 
-	if ( ! VCS_Update ( $hostname, $pf_config, $options, $options->{'branche'} ) ) {
+	if ( ! VCS_Update ( $hostname, $pf_config, $options ) ) {
 		Abort ( $CODE->{'EXEC'},
 			"Unable to checkout configuration from VCS system" );
 	}

Modified: branches/next-gen/lib/PFTools/VCS.pm
URL: http://svn.debian.org/wsvn/pf-tools/branches/next-gen/lib/PFTools/VCS.pm?rev=811&op=diff
==============================================================================
--- branches/next-gen/lib/PFTools/VCS.pm (original)
+++ branches/next-gen/lib/PFTools/VCS.pm Fri Aug  6 12:28:28 2010
@@ -36,21 +36,21 @@
 );
 
 # Updating CVS repository
-sub __CVS_update ($$;$$) {
-	my ( $hostname, $pf_config, $options, $branche ) = @_;
+sub __CVS_update ($$$) {
+	my ( $hostname, $pf_config, $options ) = @_;
 	my $cvs_cmd = $pf_config->{'vcs'}->{'command'};
 
-	if ( $branche ne '' ) {
+	if ( defined $options->{'branch'} && $options->{'branch'} ne '' ) {
 		if ( $cvs_cmd ne '' ) {
 			Warn ( $CODE->{'DUPLICATE_VALUE'},
-				"Ignoring CVS command ".$cvs_cmd." for using branche ".$branche );
+				"Ignoring CVS command ".$cvs_cmd." for using branche ".$options->{'branch'} );
 		}
 	}
 	elsif ( $pf_config->{'vcs'}->{'branch'} ) {
-		$branche = $pf_config->{'vcs'}->{'branch'};
+		$options->{'branch'} = $pf_config->{'vcs'}->{'branch'};
 	}
 	else {
-		$branche = "";
+		$options->{'branch'} = "";
 	}
 
 	my $ret;
@@ -69,7 +69,7 @@
 				.$pf_config->{'vcs'}->{'server'} 
 		}
 		$cvs_cmd .= $pf_config->{'vcs'}->{'vcsroot'}."' checkout ";
-		$cvs_cmd .= ' -r '.$branche if ( $branche ne "" );
+		$cvs_cmd .= ' -r '.$options->{'branch'} if ( $options->{'branch'} ne "" );
 		$cvs_cmd .= $pf_config->{'vcs'}->{'module'};
 	}
     print $cvs_cmd."\n" if ( $options->{'debug'} || $options->{'verbose'} );
@@ -90,11 +90,11 @@
     return $ret;
 }
 
-sub VCS_update ($$$;$) {
-	my ( $hostname, $pf_config, $options, $branch ) = @_;
+sub VCS_update ($$$) {
+	my ( $hostname, $pf_config, $options ) = @_;
 
 	if ( $pf_config->{'vcs'}->{'type'} eq 'cvs' ) {
-		if ( __CVS_update ( $hostname, $pf_config, $options, $branch ) ) {
+		if ( __CVS_update ( $hostname, $pf_config, $options ) ) {
 			return 0;
 		}
 	}




More information about the pf-tools-commits mailing list