diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2007-05-01 22:26:14 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2007-05-01 22:26:14 +0000 |
commit | 9b5d2d24a3b27c0c543aea1b41400afd3a7d874d (patch) | |
tree | d849f3a398e6b84da127d90d914d48fd494693a5 | |
parent | 47944c7c2d90e46157bab0308f10c5d4d7349aab (diff) | |
download | pfsense-9b5d2d24a3b27c0c543aea1b41400afd3a7d874d.zip pfsense-9b5d2d24a3b27c0c543aea1b41400afd3a7d874d.tar.gz |
Exit if URL or PATH is blank.
-rwxr-xr-x | etc/rc.initial.firmware_update | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/etc/rc.initial.firmware_update b/etc/rc.initial.firmware_update index 749207e..8bb6a7b 100755 --- a/etc/rc.initial.firmware_update +++ b/etc/rc.initial.firmware_update @@ -36,6 +36,8 @@ switch ($command) { case "1": echo "\nEnter the URL to the .tgz update file:\n> "; $url = chop(fgets($fp)); + if(!$url) + die; $status = does_url_exist($url); if($status) { echo "\nFetching file...\n"; @@ -65,6 +67,8 @@ switch ($command) { case "2": echo "\nEnter the complete path to the .tgz update file: "; $path = chop(fgets($fp)); + if(!$path) + die; if(file_exists($path)) { do_upgrade($path); } else { |