Flush write buffer before reading.
@@ -612,6 +612,10 @@ papplDeviceRead(
if (!device)
return (-1);
+ // Make sure any pending IO is flushed...
+ if (device->bufused > 0)
+ papplDeviceFlush(device);
+
gettimeofday(&starttime, NULL);
if (device->fd >= 0)
