diff options
author | Romain d'Alverny <rda@mageia.org> | 2012-09-05 15:07:29 +0000 |
---|---|---|
committer | Romain d'Alverny <rda@mageia.org> | 2012-09-05 15:07:29 +0000 |
commit | 4f4061ca4e3cb4eed76b6ecfcb6d3a0a2d609bb7 (patch) | |
tree | 6a37b89a3b2b1a5a3be49fd4be8cf142d110a137 | |
parent | b6c6c47fd28fb82cc3fdc12fc11e7fc8bf0ed651 (diff) | |
download | pkgsubmit-4f4061ca4e3cb4eed76b6ecfcb6d3a0a2d609bb7.tar pkgsubmit-4f4061ca4e3cb4eed76b6ecfcb6d3a0a2d609bb7.tar.gz pkgsubmit-4f4061ca4e3cb4eed76b6ecfcb6d3a0a2d609bb7.tar.bz2 pkgsubmit-4f4061ca4e3cb4eed76b6ecfcb6d3a0a2d609bb7.tar.xz pkgsubmit-4f4061ca4e3cb4eed76b6ecfcb6d3a0a2d609bb7.zip |
restore CWD when leaving the function
-rw-r--r-- | lib.php | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -28,6 +28,7 @@ */ function get_submitted_packages($upload_dir, $max_modified) { + $cwd = getcwd(); chdir($upload_dir); $matches = array(); @@ -38,6 +39,8 @@ function get_submitted_packages($upload_dir, $max_modified) $matches, PREG_SET_ORDER); + chdir($cwd); + return $matches; } |