Fix catching rmdir on file

This commit is contained in:
Robin Appelman 2014-07-15 16:42:09 +02:00
commit 1c2745ccf2

View file

@ -105,7 +105,7 @@ class NativeShare implements IShare {
throw new AlreadyExistsException($errstr);
} else if (strpos($errstr, 'Can\'t write to a directory') or
strpos($errstr, 'use rmdir instead') or
$errno === 20 // 20: ENOTDIR
strpos($errstr, 'unknown error (20)') // 20: ENOTDIR
) {
throw new InvalidTypeException($errstr);
} else if (strpos($errstr, 'Workgroup not found') or