diff --git a/QtScrcpy/device/controller/inputconvert/controlmsg.cpp b/QtScrcpy/device/controller/inputconvert/controlmsg.cpp index a8ba69d..6a21634 100644 --- a/QtScrcpy/device/controller/inputconvert/controlmsg.cpp +++ b/QtScrcpy/device/controller/inputconvert/controlmsg.cpp @@ -128,7 +128,7 @@ QByteArray ControlMsg::serializeData() break; case CMT_SET_CLIPBOARD: buffer.putChar(!!m_data.setClipboard.paste); - BufferUtil::write16(buffer, static_cast(strlen(m_data.setClipboard.text))); + BufferUtil::write32(buffer, static_cast(strlen(m_data.setClipboard.text))); buffer.write(m_data.setClipboard.text, strlen(m_data.setClipboard.text)); break; case CMT_SET_SCREEN_POWER_MODE: