Reverted 6235bc0
authorAlexander Ebert <ebert@woltlab.com>
Sun, 13 Jan 2013 21:10:41 +0000 (22:10 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Sun, 13 Jan 2013 21:10:41 +0000 (22:10 +0100)
wcfsetup/install/files/lib/system/io/TarWriter.class.php

index 9056f0b03ada9c3598b33a8160f82067f157fd42..4538beb6f79de201deac167cec35afbc97a311b8 100644 (file)
@@ -143,8 +143,8 @@ class TarWriter extends Tar {
        protected function addFile($filename, $addDir, $removeDir) {
                $filename = FileUtil::unifyDirSeperator($filename);
                $storedFilename = $filename;
-               if (!empty($removeDir)) $storedFilename = StringUtil::replaceIgnoreCase(FileUtil::addTrailingSlash($removeDir), '', $filename);
-               if (!empty($addDir)) $storedFilename = FileUtil::addTrailingSlash($addDir) . FileUtil::removeLeadingSlash($storedFilename);
+               if (!empty($removeDir)) $storedFilename = StringUtil::replaceIgnoreCase($removeDir, '', $filename);
+               if (!empty($addDir)) $storedFilename = $addDir . $storedFilename;
                
                if (is_file($filename)) {
                        // open file