1
0
Fork 0

Merge pull request #1781 from qcho/symlinkfix

Fix case where PHP's symlink returns false without any error or warning.
pull/1782/head
Jordi Boggiano 2013-04-09 00:01:14 -07:00
commit c86a723026
1 changed files with 3 additions and 1 deletions

View File

@ -217,7 +217,9 @@ class LibraryInstaller implements InstallerInterface
// when using it in smbfs mounted folder
$relativeBin = $this->filesystem->findShortestPath($link, $binPath);
chdir(dirname($link));
symlink($relativeBin, $link);
if (false === symlink($relativeBin, $link)) {
throw new \ErrorException();
}
} catch (\ErrorException $e) {
file_put_contents($link, $this->generateUnixyProxyCode($binPath, $link));
}