do not use buffered file IO
This is not necessary here. Additionally we can use O_CLOEXEC to make sure the file descriptors are not leaked by accident.
Differential Revision: https://phabricator.kde.org/D13100