mIRC should be closing the file handle to mirc.ini when it's not writing anything to it. There shouldn't be very many occasions when writing to mirc.ini anyway, since the mirc.ini contents are loaded into memory and cached on load and only written back out on exit or an explicit call to /flushini mirc.ini, from what I understand. This would solve the high chance of mirc.ini corruption without having to fflush.