projects
/
yaffs-website
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website]
/
vendor
/
mikey179
/
vfsStream
/
src
/
main
/
php
/
org
/
bovigo
/
vfs
/
content
/
SeekableFileContent.php
diff --git
a/vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/content/SeekableFileContent.php
b/vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/content/SeekableFileContent.php
index e74800083868acf56917a394d9bb88b83e96f863..e4c3d9b0a4c9f7d1030fdff98ba923656928538f 100644
(file)
--- a/
vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/content/SeekableFileContent.php
+++ b/
vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/content/SeekableFileContent.php
@@
-52,24
+52,29
@@
abstract class SeekableFileContent implements FileContent
*/
public function seek($offset, $whence)
{
*/
public function seek($offset, $whence)
{
+ $newOffset = $this->offset;
switch ($whence) {
case SEEK_CUR:
switch ($whence) {
case SEEK_CUR:
- $
this->o
ffset += $offset;
-
return true
;
+ $
newO
ffset += $offset;
+
break
;
case SEEK_END:
case SEEK_END:
- $
this->o
ffset = $this->size() + $offset;
-
return true
;
+ $
newO
ffset = $this->size() + $offset;
+
break
;
case SEEK_SET:
case SEEK_SET:
- $
this->o
ffset = $offset;
-
return true
;
+ $
newO
ffset = $offset;
+
break
;
default:
return false;
}
default:
return false;
}
-
- return false;
+
+ if ($newOffset<0) {
+ return false;
+ }
+ $this->offset = $newOffset;
+ return true;
}
/**
}
/**