1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 22:48:11 +00:00

CIODevice: Add a virtual did_update_fd() no notify subclasses of fd change.

This will allow subclasses to react when the file descriptor changes.
This commit is contained in:
Andreas Kling 2019-07-27 10:47:46 +02:00
parent 8ed078e5b2
commit 8f4fba95c0
2 changed files with 12 additions and 1 deletions

View file

@ -241,3 +241,12 @@ int CIODevice::printf(const char* format, ...)
va_end(ap);
return ret;
}
void CIODevice::set_fd(int fd)
{
if (m_fd == fd)
return;
m_fd = fd;
did_update_fd(fd);
}