1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-23 20:15:06 +00:00

Pass the process to CharacterDevice::read/write.

This is much nicer than grabbing directly at 'current' inside a read().
This commit is contained in:
Andreas Kling 2019-01-16 00:20:38 +01:00
parent 08bfe518f9
commit bd3e77cc16
27 changed files with 63 additions and 62 deletions

View file

@ -17,12 +17,12 @@ bool NullDevice::can_read(Process&) const
return true;
}
ssize_t NullDevice::read(byte*, size_t)
ssize_t NullDevice::read(Process&, byte*, size_t)
{
return 0;
}
ssize_t NullDevice::write(const byte*, size_t bufferSize)
ssize_t NullDevice::write(Process&, const byte*, size_t bufferSize)
{
return min(GoodBufferSize, bufferSize);
}