update icewind/smb to 3.0.1
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
3e72cc16e7
commit
23d4e910a8
|
@ -9,6 +9,6 @@
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"icewind/streams": "0.6.1",
|
"icewind/streams": "0.6.1",
|
||||||
"icewind/smb": "3.0.0"
|
"icewind/smb": "3.0.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,20 +4,20 @@
|
||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "1465c8a4b4139e514086d5803d90af2d",
|
"content-hash": "2cf7fdc531a149399b36b1a7a92ba79b",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "icewind/smb",
|
"name": "icewind/smb",
|
||||||
"version": "v3.0.0",
|
"version": "v3.0.1",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/icewind1991/SMB.git",
|
"url": "https://github.com/icewind1991/SMB.git",
|
||||||
"reference": "0d31da4757a37d322e1e181f2286e8a4c89fbc0c"
|
"reference": "bd43cdecd09ffe289fd2881761d4c72e60c95aeb"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/icewind1991/SMB/zipball/0d31da4757a37d322e1e181f2286e8a4c89fbc0c",
|
"url": "https://api.github.com/repos/icewind1991/SMB/zipball/bd43cdecd09ffe289fd2881761d4c72e60c95aeb",
|
||||||
"reference": "0d31da4757a37d322e1e181f2286e8a4c89fbc0c",
|
"reference": "bd43cdecd09ffe289fd2881761d4c72e60c95aeb",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
@ -45,7 +45,7 @@
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"description": "php wrapper for smbclient and libsmbclient-php",
|
"description": "php wrapper for smbclient and libsmbclient-php",
|
||||||
"time": "2018-05-24T09:48:51+00:00"
|
"time": "2019-02-06T16:53:32+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "icewind/streams",
|
"name": "icewind/streams",
|
||||||
|
|
|
@ -279,7 +279,7 @@ class ClassLoader
|
||||||
*/
|
*/
|
||||||
public function setApcuPrefix($apcuPrefix)
|
public function setApcuPrefix($apcuPrefix)
|
||||||
{
|
{
|
||||||
$this->apcuPrefix = function_exists('apcu_fetch') && ini_get('apc.enabled') ? $apcuPrefix : null;
|
$this->apcuPrefix = function_exists('apcu_fetch') && filter_var(ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? $apcuPrefix : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -377,7 +377,7 @@ class ClassLoader
|
||||||
$subPath = $class;
|
$subPath = $class;
|
||||||
while (false !== $lastPos = strrpos($subPath, '\\')) {
|
while (false !== $lastPos = strrpos($subPath, '\\')) {
|
||||||
$subPath = substr($subPath, 0, $lastPos);
|
$subPath = substr($subPath, 0, $lastPos);
|
||||||
$search = $subPath.'\\';
|
$search = $subPath . '\\';
|
||||||
if (isset($this->prefixDirsPsr4[$search])) {
|
if (isset($this->prefixDirsPsr4[$search])) {
|
||||||
$pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1);
|
$pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1);
|
||||||
foreach ($this->prefixDirsPsr4[$search] as $dir) {
|
foreach ($this->prefixDirsPsr4[$search] as $dir) {
|
||||||
|
|
|
@ -72,21 +72,6 @@ return array(
|
||||||
'Icewind\\Streams\\PathWrapper' => $vendorDir . '/icewind/streams/src/PathWrapper.php',
|
'Icewind\\Streams\\PathWrapper' => $vendorDir . '/icewind/streams/src/PathWrapper.php',
|
||||||
'Icewind\\Streams\\RetryWrapper' => $vendorDir . '/icewind/streams/src/RetryWrapper.php',
|
'Icewind\\Streams\\RetryWrapper' => $vendorDir . '/icewind/streams/src/RetryWrapper.php',
|
||||||
'Icewind\\Streams\\SeekableWrapper' => $vendorDir . '/icewind/streams/src/SeekableWrapper.php',
|
'Icewind\\Streams\\SeekableWrapper' => $vendorDir . '/icewind/streams/src/SeekableWrapper.php',
|
||||||
'Icewind\\Streams\\Tests\\CallbackWrapperTest' => $vendorDir . '/icewind/streams/tests/CallbackWrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Tests\\CountWrapperTest' => $vendorDir . '/icewind/streams/tests/CountWrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryFilter' => $vendorDir . '/icewind/streams/tests/DirectoryFilter.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryWrapper' => $vendorDir . '/icewind/streams/tests/DirectoryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryWrapperDummy' => $vendorDir . '/icewind/streams/tests/DirectoryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryWrapperNull' => $vendorDir . '/icewind/streams/tests/DirectoryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\FailWrapper' => $vendorDir . '/icewind/streams/tests/RetryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\IteratorDirectory' => $vendorDir . '/icewind/streams/tests/IteratorDirectory.php',
|
|
||||||
'Icewind\\Streams\\Tests\\NullWrapperTest' => $vendorDir . '/icewind/streams/tests/NullWrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Tests\\PartialWrapper' => $vendorDir . '/icewind/streams/tests/RetryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\PathWrapper' => $vendorDir . '/icewind/streams/tests/PathWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\RetryWrapperTest' => $vendorDir . '/icewind/streams/tests/RetryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\SeekableWrapper' => $vendorDir . '/icewind/streams/tests/SeekableWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\UrlCallBack' => $vendorDir . '/icewind/streams/tests/UrlCallBack.php',
|
|
||||||
'Icewind\\Streams\\Tests\\WrapperTest' => $vendorDir . '/icewind/streams/tests/WrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Url' => $vendorDir . '/icewind/streams/src/Url.php',
|
'Icewind\\Streams\\Url' => $vendorDir . '/icewind/streams/src/Url.php',
|
||||||
'Icewind\\Streams\\UrlCallback' => $vendorDir . '/icewind/streams/src/UrlCallBack.php',
|
'Icewind\\Streams\\UrlCallback' => $vendorDir . '/icewind/streams/src/UrlCallBack.php',
|
||||||
'Icewind\\Streams\\Wrapper' => $vendorDir . '/icewind/streams/src/Wrapper.php',
|
'Icewind\\Streams\\Wrapper' => $vendorDir . '/icewind/streams/src/Wrapper.php',
|
||||||
|
|
|
@ -102,21 +102,6 @@ class ComposerStaticInit98fe9b281934250b3a93f69a5ce843b3
|
||||||
'Icewind\\Streams\\PathWrapper' => __DIR__ . '/..' . '/icewind/streams/src/PathWrapper.php',
|
'Icewind\\Streams\\PathWrapper' => __DIR__ . '/..' . '/icewind/streams/src/PathWrapper.php',
|
||||||
'Icewind\\Streams\\RetryWrapper' => __DIR__ . '/..' . '/icewind/streams/src/RetryWrapper.php',
|
'Icewind\\Streams\\RetryWrapper' => __DIR__ . '/..' . '/icewind/streams/src/RetryWrapper.php',
|
||||||
'Icewind\\Streams\\SeekableWrapper' => __DIR__ . '/..' . '/icewind/streams/src/SeekableWrapper.php',
|
'Icewind\\Streams\\SeekableWrapper' => __DIR__ . '/..' . '/icewind/streams/src/SeekableWrapper.php',
|
||||||
'Icewind\\Streams\\Tests\\CallbackWrapperTest' => __DIR__ . '/..' . '/icewind/streams/tests/CallbackWrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Tests\\CountWrapperTest' => __DIR__ . '/..' . '/icewind/streams/tests/CountWrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryFilter' => __DIR__ . '/..' . '/icewind/streams/tests/DirectoryFilter.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryWrapper' => __DIR__ . '/..' . '/icewind/streams/tests/DirectoryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryWrapperDummy' => __DIR__ . '/..' . '/icewind/streams/tests/DirectoryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\DirectoryWrapperNull' => __DIR__ . '/..' . '/icewind/streams/tests/DirectoryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\FailWrapper' => __DIR__ . '/..' . '/icewind/streams/tests/RetryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\IteratorDirectory' => __DIR__ . '/..' . '/icewind/streams/tests/IteratorDirectory.php',
|
|
||||||
'Icewind\\Streams\\Tests\\NullWrapperTest' => __DIR__ . '/..' . '/icewind/streams/tests/NullWrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Tests\\PartialWrapper' => __DIR__ . '/..' . '/icewind/streams/tests/RetryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\PathWrapper' => __DIR__ . '/..' . '/icewind/streams/tests/PathWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\RetryWrapperTest' => __DIR__ . '/..' . '/icewind/streams/tests/RetryWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\SeekableWrapper' => __DIR__ . '/..' . '/icewind/streams/tests/SeekableWrapper.php',
|
|
||||||
'Icewind\\Streams\\Tests\\UrlCallBack' => __DIR__ . '/..' . '/icewind/streams/tests/UrlCallBack.php',
|
|
||||||
'Icewind\\Streams\\Tests\\WrapperTest' => __DIR__ . '/..' . '/icewind/streams/tests/WrapperTest.php',
|
|
||||||
'Icewind\\Streams\\Url' => __DIR__ . '/..' . '/icewind/streams/src/Url.php',
|
'Icewind\\Streams\\Url' => __DIR__ . '/..' . '/icewind/streams/src/Url.php',
|
||||||
'Icewind\\Streams\\UrlCallback' => __DIR__ . '/..' . '/icewind/streams/src/UrlCallBack.php',
|
'Icewind\\Streams\\UrlCallback' => __DIR__ . '/..' . '/icewind/streams/src/UrlCallBack.php',
|
||||||
'Icewind\\Streams\\Wrapper' => __DIR__ . '/..' . '/icewind/streams/src/Wrapper.php',
|
'Icewind\\Streams\\Wrapper' => __DIR__ . '/..' . '/icewind/streams/src/Wrapper.php',
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"name": "icewind/smb",
|
"name": "icewind/smb",
|
||||||
"version": "v3.0.0",
|
"version": "v3.0.1",
|
||||||
"version_normalized": "3.0.0.0",
|
"version_normalized": "3.0.1.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/icewind1991/SMB.git",
|
"url": "https://github.com/icewind1991/SMB.git",
|
||||||
"reference": "0d31da4757a37d322e1e181f2286e8a4c89fbc0c"
|
"reference": "bd43cdecd09ffe289fd2881761d4c72e60c95aeb"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/icewind1991/SMB/zipball/0d31da4757a37d322e1e181f2286e8a4c89fbc0c",
|
"url": "https://api.github.com/repos/icewind1991/SMB/zipball/bd43cdecd09ffe289fd2881761d4c72e60c95aeb",
|
||||||
"reference": "0d31da4757a37d322e1e181f2286e8a4c89fbc0c",
|
"reference": "bd43cdecd09ffe289fd2881761d4c72e60c95aeb",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
@ -21,7 +21,7 @@
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"phpunit/phpunit": "^5.7"
|
"phpunit/phpunit": "^5.7"
|
||||||
},
|
},
|
||||||
"time": "2018-05-24T09:48:51+00:00",
|
"time": "2019-02-06T16:53:32+00:00",
|
||||||
"type": "library",
|
"type": "library",
|
||||||
"installation-source": "dist",
|
"installation-source": "dist",
|
||||||
"autoload": {
|
"autoload": {
|
||||||
|
|
|
@ -16,6 +16,8 @@ class System {
|
||||||
|
|
||||||
private $stdbuf;
|
private $stdbuf;
|
||||||
|
|
||||||
|
private $date;
|
||||||
|
|
||||||
public static function getFD($num) {
|
public static function getFD($num) {
|
||||||
$folders = [
|
$folders = [
|
||||||
'/proc/self/fd',
|
'/proc/self/fd',
|
||||||
|
@ -43,6 +45,13 @@ class System {
|
||||||
return $this->net;
|
return $this->net;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getDatePath() {
|
||||||
|
if (!$this->date) {
|
||||||
|
$this->date = trim(`which date`);
|
||||||
|
}
|
||||||
|
return $this->date;
|
||||||
|
}
|
||||||
|
|
||||||
public function hasStdBuf() {
|
public function hasStdBuf() {
|
||||||
if (!$this->stdbuf) {
|
if (!$this->stdbuf) {
|
||||||
$result = null;
|
$result = null;
|
||||||
|
|
|
@ -43,10 +43,13 @@ class TimeZoneProvider {
|
||||||
);
|
);
|
||||||
$this->timeZone = exec($command);
|
$this->timeZone = exec($command);
|
||||||
}
|
}
|
||||||
|
if (!$this->timeZone) { // fallback to server timezone
|
||||||
if ($this->timeZone) {
|
$date = $this->system->getDatePath();
|
||||||
// fallback to server timezone
|
if ($date) {
|
||||||
$this->timeZone = date_default_timezone_get();
|
$this->timeZone = exec($date . " +%z");
|
||||||
|
} else {
|
||||||
|
$this->timeZone = date_default_timezone_get();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $this->timeZone;
|
return $this->timeZone;
|
||||||
|
|
|
@ -13,7 +13,6 @@ use Icewind\SMB\Exception\DependencyException;
|
||||||
use Icewind\SMB\Exception\FileInUseException;
|
use Icewind\SMB\Exception\FileInUseException;
|
||||||
use Icewind\SMB\Exception\InvalidTypeException;
|
use Icewind\SMB\Exception\InvalidTypeException;
|
||||||
use Icewind\SMB\Exception\NotFoundException;
|
use Icewind\SMB\Exception\NotFoundException;
|
||||||
use Icewind\SMB\IFileInfo;
|
|
||||||
use Icewind\SMB\INotifyHandler;
|
use Icewind\SMB\INotifyHandler;
|
||||||
use Icewind\SMB\IServer;
|
use Icewind\SMB\IServer;
|
||||||
use Icewind\SMB\System;
|
use Icewind\SMB\System;
|
||||||
|
@ -159,13 +158,14 @@ class Share extends AbstractShare {
|
||||||
if ($path !== "" && $path !== "/") {
|
if ($path !== "" && $path !== "/") {
|
||||||
$parent = dirname($path);
|
$parent = dirname($path);
|
||||||
$dir = $this->dir($parent);
|
$dir = $this->dir($parent);
|
||||||
$file = array_values(array_filter($dir, function(IFileInfo $info) use ($path) {
|
$file = array_values(array_filter($dir, function(FileInfo $info) use ($path) {
|
||||||
return $info->getPath() === $path;
|
return $info->getPath() === $path;
|
||||||
}));
|
}));
|
||||||
if ($file) {
|
if ($file) {
|
||||||
return $file[0];
|
return $file[0];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$escapedPath = $this->escapePath($path);
|
$escapedPath = $this->escapePath($path);
|
||||||
$output = $this->execute('allinfo ' . $escapedPath);
|
$output = $this->execute('allinfo ' . $escapedPath);
|
||||||
// Windows and non Windows Fileserver may respond different
|
// Windows and non Windows Fileserver may respond different
|
||||||
|
|
Loading…
Reference in New Issue