diff options
author | Colin Smith <colin@pfsense.org> | 2005-04-07 16:50:04 +0000 |
---|---|---|
committer | Colin Smith <colin@pfsense.org> | 2005-04-07 16:50:04 +0000 |
commit | 0b26b9eac5e3edb5886b3444ef3835dedb9f7028 (patch) | |
tree | f8d60bd27aa52e5d39988102280550b036c98800 /usr/local/www/system_firmware_auto.php | |
parent | f9015e1edadea4ddce244228ab498f1f276860b8 (diff) | |
download | pfsense-0b26b9eac5e3edb5886b3444ef3835dedb9f7028.zip pfsense-0b26b9eac5e3edb5886b3444ef3835dedb9f7028.tar.gz |
Exit script if we are unable to retrive version information.
Diffstat (limited to 'usr/local/www/system_firmware_auto.php')
-rwxr-xr-x | usr/local/www/system_firmware_auto.php | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/usr/local/www/system_firmware_auto.php b/usr/local/www/system_firmware_auto.php index 88e07ce..b027644 100755 --- a/usr/local/www/system_firmware_auto.php +++ b/usr/local/www/system_firmware_auto.php @@ -91,10 +91,15 @@ $base_version = trim(file_get_contents('/etc/version_base')); update_status("Downloading current version information..."); $versions = check_firmware_version(); -if($versions[0] != $firmware_version) $needs_firmware_upgrade = true; -if($versions[1] != $kernel_version) $needs_kernel_upgrade = true; -if($versions[2] != $base_version) $needs_base_version = true; -// if(isset($versions[3])) update_output_window($versions[3]); // If we have additional data (a CHANGELOG etc) to display, do so. +if($versions != -1) { + if($versions[0] != $firmware_version) $needs_firmware_upgrade = true; + if($versions[1] != $kernel_version) $needs_kernel_upgrade = true; + if($versions[2] != $base_version) $needs_base_version = true; + // if(isset($versions[3])) update_output_window($versions[3]); // If we have additional data (a CHANGELOG etc) to display, do so. +} else { + update_status("Could not retrieve version information."); + exit(); +} if($needs_firmware_upgrade == true) { update_status("Downloading firmware update..."); |