pf-tools commit: r733 [ccaillet-guest] - in /trunk: debian/changelog lib/PFTools/Update.pm
parmelan-guest at users.alioth.debian.org
parmelan-guest at users.alioth.debian.org
Fri Dec 11 15:07:31 UTC 2009
Author: ccaillet-guest
Date: Fri Dec 11 15:07:26 2009
New Revision: 733
URL: http://svn.debian.org/wsvn/pf-tools/?sc=1&rev=733
Log:
lib/PFTools/Update.pm : avoid multiple calls for updating the repository
content (fix regression)
Modified:
trunk/debian/changelog
trunk/lib/PFTools/Update.pm
Modified: trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pf-tools/trunk/debian/changelog?rev=733&op=diff
==============================================================================
--- trunk/debian/changelog (original)
+++ trunk/debian/changelog Fri Dec 11 15:07:26 2009
@@ -55,6 +55,8 @@
- Get_conf: sort readdir result, in order to always read update-hostname
before update-hostname01 (thus allowing to ignore in update-hostname01 a
section defined in update-hostname).
+ * lib/PFTools/Update.pm : avoid multiple calls for updating the repository
+ content (fix regression)
[ Thomas Parmelan ]
* debian/control
@@ -76,7 +78,7 @@
* tools/kvmlaunch:
- new script.
- -- Christophe Caillet <quadchris at free.fr> Mon, 07 Dec 2009 16:42:19 +0100
+ -- Christophe Caillet <quadchris at free.fr> Fri, 11 Dec 2009 16:01:08 +0100
pf-tools (0.33.1-1) unstable; urgency=low
Modified: trunk/lib/PFTools/Update.pm
URL: http://svn.debian.org/wsvn/pf-tools/trunk/lib/PFTools/Update.pm?rev=733&op=diff
==============================================================================
--- trunk/lib/PFTools/Update.pm (original)
+++ trunk/lib/PFTools/Update.pm Fri Dec 11 15:07:26 2009
@@ -594,17 +594,15 @@
return 0;
};
-sub aptupdate {
- my $pkg;
+sub aptupdate ($){
+ my ( $pkg_type ) = @_ ;
if ($APT_UPDATE) {
- if ( deferredlogsystem( $APT_GET . " update" ) ) {
- Warn( $ERR_OPEN, "apt-get update failed!" );
+ if ( ! Update_pkg_repository ( $pkg_type ) ) {
return 1;
- }
- $APT_UPDATE = 0;
- }
-
+ }
+ $APT_UPDATE = 0;
+ }
return 0;
}
@@ -612,12 +610,10 @@
my ( $S, $dest, $options, $pkg_type ) = @_;
$pkg_type = 'deb' if ( ! defined $pkg_type ) ;
-# if ( aptupdate() ) {
-# return 1;
-# }
- if ( ! Update_pkg_repository ( $pkg_type ) ) {
+ if ( aptupdate( $pkg_type ) ) {
return 1;
}
+
# open( APTDEP, $APT_GET_DEPENDS . ' install ' . $dest . ' 2>/dev/null |' );
# while (<APTDEP>) {
@@ -666,8 +662,7 @@
$dest = $newdest;
}
-# aptupdate();
- Update_pkg_repository ( $pkg_type ) ;
+ aptupdate( $pkg_type );
# open( APTPOLICY, $APT_POLICY . ' ' . $dest . ' 2>/dev/null |' );
# while (<APTPOLICY>) {
More information about the pf-tools-commits
mailing list