From a764453f3f8be8a790ddd969639b36bd5f21641e Mon Sep 17 00:00:00 2001 From: Colin Smith Date: Wed, 13 Apr 2005 23:10:14 +0000 Subject: Fix logic that checks whether a package is already installed. --- usr/local/www/pkg_mgr_install.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'usr/local/www/pkg_mgr_install.php') diff --git a/usr/local/www/pkg_mgr_install.php b/usr/local/www/pkg_mgr_install.php index 8d197a0..2a3c0da 100755 --- a/usr/local/www/pkg_mgr_install.php +++ b/usr/local/www/pkg_mgr_install.php @@ -171,7 +171,7 @@ foreach ($packages_to_install as $id) { * Make sure that this package isn't already installed. */ - if(get_pkg_id($pkg_config['packages']['package'][$id]['name']) == -1) continue; + if(get_pkg_id($pkg_config['packages']['package'][$id]['name']) != -1) continue; /* * install the package @@ -470,9 +470,8 @@ foreach ($packages_to_install as $id) { $static_output .= "\nPackage installation successful."; update_output_window($static_output); fwrite($fd_log, "Package installation completed.\n"); - log_error("Package " . $pkgent['name'] . " installation completed successfully."); + log_error("Package " . $pkgent['name'] . " installation completed successfully.\n"); fwrite($fd_log, "Status window output:\n" . $static_output); - unlink_if_exists("/ } // Delete all temporary package tarballs and staging areas. -- cgit v1.1