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

Kernel+LibC: Fix various build issues introduced by ssize_t

Now that ssize_t is derived from size_t, we have to
This commit is contained in:
Andreas Kling 2020-05-23 15:27:33 +02:00
parent 2fe6b3725a
commit dd924b730a
14 changed files with 15 additions and 16 deletions

View file

@ -46,14 +46,14 @@ bool ZeroDevice::can_read(const FileDescription&, size_t) const
ssize_t ZeroDevice::read(FileDescription&, size_t, u8* buffer, ssize_t size)
{
ssize_t count = min(PAGE_SIZE, size);
ssize_t count = min(static_cast<ssize_t>(PAGE_SIZE), size);
memset(buffer, 0, (size_t)count);
return count;
}
ssize_t ZeroDevice::write(FileDescription&, size_t, const u8*, ssize_t size)
{
return min(PAGE_SIZE, size);
return min(static_cast<ssize_t>(PAGE_SIZE), size);
}
}