Remove error handling in clientCutText()

It is not necessary as Websock.flush() is guaranteed to succeed and
give us some space. It also remove the call to _fail(), which was
invalid at this place as clientCutText() is not a method on RFB.
This commit is contained in:
Pierre Ossman 2019-02-15 13:14:36 +01:00 committed by Lauri Kasanen
parent d20f751441
commit 499b251716

View File

@ -2024,11 +2024,6 @@ RFB.messages = {
while (remaining > 0) {
let flushSize = Math.min(remaining, (sock._sQbufferSize - sock._sQlen));
if (flushSize <= 0) {
this._fail("Clipboard contents could not be sent");
break;
}
for (let i = 0; i < flushSize; i++) {
buff[sock._sQlen + i] = text.charCodeAt(textOffset + i);
}