Fixed bin proxies on PHP < 8 to support stream_seek (#10468)

main
John Stevenson 2 years ago committed by GitHub
parent 6a70161c01
commit db64534b26
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -333,6 +333,16 @@ if (PHP_VERSION_ID < 80000) {
return \$operation ? flock(\$this->handle, \$operation) : true;
}
public function stream_seek(\$offset, \$whence)
{
if (0 === fseek(\$this->handle, \$offset, \$whence)) {
\$this->position = ftell(\$this->handle);
return true;
}
return false;
}
public function stream_tell()
{
return \$this->position;

Loading…
Cancel
Save