Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash after trying to paste computer clipboard with ctrl+v #10

Closed
MCMic opened this issue Mar 9, 2018 · 1 comment
Closed

Crash after trying to paste computer clipboard with ctrl+v #10

MCMic opened this issue Mar 9, 2018 · 1 comment
Assignees
Labels

Comments

@MCMic
Copy link

MCMic commented Mar 9, 2018

I got a crash when trying to paste computer clipboard with ctrl+v:

/usr/share/scrcpy/scrcpy-server.jar: 1 file pushed. 1.7 MB/s (19038 bytes in 0.011s)
INFO: Initial texture: 540x960
*** buffer overflow detected ***: scrcpy terminated
fish: Tâche -1667279360, 'scrcpy' terminée par le signal SIGABRT (Abandon)

Please tell me if you need details/testing.
(I used the PKGBUILD from https://linuxfr.org/users/rom1v/journaux/scrcpy-une-appli-pour-afficher-et-controler-des-devices-android#comment-1731993 to install, phone has lineageos from february)

@rom1v rom1v self-assigned this Mar 9, 2018
@rom1v rom1v added the bug label Mar 9, 2018
rom1v added a commit that referenced this issue Mar 9, 2018
The text input control_event was initially designed for mapping
SDL_TextInputEvent, limited to 32 characters.

For simplicity, the copy/paste feature was implemented using the same
control_event: it just sends the text to paste.

However, the pasted text might have a length breaking some assumptions:
 - on the client, the event max-size was smaller than the text
   max-length,
 - on the server, the raw buffer storing the events was smaller than the
   max event size.

Fix these inconsistencies, and encode the length on 2 bytes, to accept
more than 256 characters.

Fixes <#10>.
@rom1v
Copy link
Collaborator

rom1v commented Mar 9, 2018

Fixed on dev branch.

Since it involves non-backward compatible changes in the protocol for sending events, it will be on master only when the next release is out (to avoid people compiling master using the old incompatible prebuilt server)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants