+ while (device->bytesToWrite() > 16*1024) {
+ int timeout = device->bytesToWrite() >= 128*1024 ? -1 : 0;
+ if (!device->waitForBytesWritten(timeout)) {
+ qFatal("Failed to write to process: %s", qPrintable(device->errorString()));
+ return svn_error_createf(APR_EOF, SVN_NO_ERROR, "Failed to write to process: %s",
+ qPrintable(device->errorString()));
+ }
+ }