waitForBytesWritten optionally
waitForBytesWritten is not execute when writeTimeout is less than -1.
This commit is contained in:
parent
a0bc160ea1
commit
737349ab40
|
|
@ -73,6 +73,13 @@ QDataStream &operator<<(QDataStream &stream, const QAmqpFrame &frame)
|
||||||
|
|
||||||
// write end
|
// write end
|
||||||
stream << qint8(QAmqpFrame::FRAME_END);
|
stream << qint8(QAmqpFrame::FRAME_END);
|
||||||
|
|
||||||
|
int writeTimeout = QAmqpFrame::writeTimeout();
|
||||||
|
if(writeTimeout >= -1)
|
||||||
|
{
|
||||||
|
stream.device()->waitForBytesWritten(writeTimeout);
|
||||||
|
}
|
||||||
|
|
||||||
return stream;
|
return stream;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue