diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2008-10-19 03:38:28 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2008-10-19 03:38:28 +0000 |
commit | e6d436e8d099a394bf5f8a9a573579639e236a90 (patch) | |
tree | 2e699402e311d6d5b7909d0d90adec3a08acc0d6 /etc | |
parent | 1834f481e329c403c9ff065a88757fa223a6e1c0 (diff) | |
download | pfsense-e6d436e8d099a394bf5f8a9a573579639e236a90.zip pfsense-e6d436e8d099a394bf5f8a9a573579639e236a90.tar.gz |
If <prefix> does not exist, then call safe_mkdir on it.
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/pkg-utils.inc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/etc/inc/pkg-utils.inc b/etc/inc/pkg-utils.inc index 35ea943..cb77914 100644 --- a/etc/inc/pkg-utils.inc +++ b/etc/inc/pkg-utils.inc @@ -565,7 +565,9 @@ function install_package_xml($pkg) { } else { $prefix = "/usr/local/pkg/"; } - $static_output .= $filename . " "; + if(!is_dir($prefix)) + safe_mkdir($prefix); + $static_output .= $filename . " "; update_output_window($static_output); download_file_with_progress_bar($afn['item'][0], $prefix . $filename); if(stristr($filename, ".tgz") <> "") { |