summaryrefslogtreecommitdiffstats
path: root/usr/local/www/system_firmware.php
diff options
context:
space:
mode:
authorBill Marquette <billm@pfsense.org>2005-08-10 03:08:54 +0000
committerBill Marquette <billm@pfsense.org>2005-08-10 03:08:54 +0000
commit35445b1c5268597853add7218a654be1dca304af (patch)
tree8a83ceee36f0b15f2aa8a96adfb9067662a8d634 /usr/local/www/system_firmware.php
parent533ad3cfce7d65620e5d23eecfdefd6024da2daf (diff)
downloadpfsense-35445b1c5268597853add7218a654be1dca304af.zip
pfsense-35445b1c5268597853add7218a654be1dca304af.tar.gz
One more sanity check before trying to install a firmware that might not exist
Diffstat (limited to 'usr/local/www/system_firmware.php')
-rwxr-xr-xusr/local/www/system_firmware.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/usr/local/www/system_firmware.php b/usr/local/www/system_firmware.php
index d21268c..6c77980 100755
--- a/usr/local/www/system_firmware.php
+++ b/usr/local/www/system_firmware.php
@@ -90,11 +90,13 @@ if ($_POST && !file_exists($d_firmwarelock_path)) {
}
}
- if (!$input_errors && !file_exists($d_firmwarelock_path) && (!$sig_warning || $_POST['sig_override'])) {
+ if (!$input_errors && !file_exists($d_firmwarelock_path) && (!$sig_warning || $_POST['sig_override']) && file_exists("{$g['tmp_path']}/firmware.tgz")) {
/* fire up the update script in the background */
touch($d_firmwarelock_path);
$savemsg = "The firmware is now being updated. The firewall will reboot automatically.";
mwexec_bg("/etc/rc.firmware pfSenseupgrade {$g['tmp_path']}/firmware.tgz");
+ } else {
+ $savemsg = "Firmware image missing or other error, please try again.";
}
}
}
OpenPOWER on IntegriCloud