mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Report correct location when reading using explicit size and EOF reached
This commit is contained in:
parent
5ec95ba5ca
commit
2be19cfa89
@ -163,8 +163,9 @@ class MockFH(object):
|
||||
# requested size, but before doing so, reset read_data to reflect
|
||||
# what we read.
|
||||
self.read_data = self._iterate_read_data(joined[size:])
|
||||
self._loc += size
|
||||
return joined[:size]
|
||||
ret = joined[:size]
|
||||
self._loc += len(ret)
|
||||
return ret
|
||||
|
||||
def _readlines(self, size=None): # pylint: disable=unused-argument
|
||||
# TODO: Implement "size" argument
|
||||
|
Loading…
Reference in New Issue
Block a user