diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2009-09-06 15:50:22 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2009-09-06 15:50:22 -0400 |
commit | fe38f1dac4ac1b042ee445d3a72d7732344213db (patch) | |
tree | 8d2bf8d18e1869a94c106ba23262969ef77ef93d /usr | |
parent | 3350a6911bd07c283cd374880c2468de806e4769 (diff) | |
download | pfsense-fe38f1dac4ac1b042ee445d3a72d7732344213db.zip pfsense-fe38f1dac4ac1b042ee445d3a72d7732344213db.tar.gz |
Move nano check to top of function
Diffstat (limited to 'usr')
-rwxr-xr-x | usr/local/www/system_firmware.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr/local/www/system_firmware.php b/usr/local/www/system_firmware.php index dcfab93..4a8a217 100755 --- a/usr/local/www/system_firmware.php +++ b/usr/local/www/system_firmware.php @@ -52,16 +52,16 @@ ini_set('max_input_time', '9999'); function file_is_for_platform($filename) { global $g; - exec("tar xzf $filename -C /tmp/ etc/platform"); - if(!file_exists("/tmp/etc/platform")) - return false; - $upgrade_is_for_platform = trim(file_get_contents("/tmp/etc/platform")); if($g['platform'] == "nanobsd") { if(strstr($filename, "nanobsd")) return true; else return false; } + exec("tar xzf $filename -C /tmp/ etc/platform"); + if(!file_exists("/tmp/etc/platform")) + return false; + $upgrade_is_for_platform = trim(file_get_contents("/tmp/etc/platform")); if($g['platform'] == $upgrade_is_for_platform) { unlink("/tmp/etc/platform"); return true; |