#10139·deskflow

Clipboard sync loop between macOS and Windows causes multiline text to continuously grow with blank lines

Author: XinnnWCreated Sep 8, 2026Updated Sep 13, 2026

Before reporting a bug, please complete the sanity checks above.

  • I have done the sanity checks, and my issue persists.

Deskflow version info

  • Deskflow: 1.26.0.0 (760e3b99)
  • Qt: 6.10.1
  • Server: macOS Tahoe 26.5.1
  • Client: Windows
  • Clipboard sharing: enabled
  • Protocol: Barrier

Mac is used as the Deskflow server and Windows as the client.

Build types

Official release (installer/package from GitHub releases)

Deskflow configuration

none

What steps will reproduce the problem?

  1. Start Deskflow with macOS as Server and Windows as Client.
  2. Enable clipboard sharing.
  3. Open Windows clipboard history or a clipboard manager.
  4. Copy multiline plain text, for example:
AAA
BBB ad
CCC
  1. Do not perform any additional copy operations.
  2. Observe the clipboard history and Deskflow logs.

Actual behavior

Deskflow continuously detects clipboard changes and synchronizes the clipboard again.

The clipboard history shows multiple automatically generated entries from a single copy operation.

More importantly, the content grows on each synchronization round because additional blank lines/newline characters are introduced.

For example, I observed the clipboard content size growing approximately like this:

16 chars
20 chars
28 chars
44 chars
76 chars
140 chars
268 chars
...

The number of blank lines also increases on every iteration.

This continues without the user copying anything again.

Screenshot of the clipboard history shows the same content repeatedly appearing with progressively increasing blank lines and character counts.

Expected behavior

A clipboard update received from the remote machine should not be treated as a new local clipboard modification and sent back again.

For one user copy operation:

Mac clipboard changed
        ↓
Deskflow sends clipboard
        ↓
Windows clipboard updated
        ↓
STOP

The clipboard should stabilize after synchronization.

The multiline text should also preserve its original newline structure.


Observed behavior

The behavior appears to be:

clipboard change
      ↓
Deskflow sync
      ↓
remote clipboard update
      ↓
detected as another clipboard change
      ↓
Deskflow sync again
      ↓
repeat indefinitely

At the same time, the text representation changes slightly on each round, causing blank lines to accumulate.


Possible area to investigate

This part is only a hypothesis based on the observed behavior.

It may be related to the interaction between:

  • clipboard ownership / echo suppression
  • clipboard content comparison
  • Windows CRLF (\r\n) and macOS LF (\n) normalization
  • multiple clipboard types/formats (clipboard 0 and clipboard 1)

If Deskflow writes clipboard data received from the peer and the platform subsequently reports that write as a new local clipboard change, the clipboard could be sent back to the original machine.

If newline normalization changes the payload during that process, content-based duplicate detection may also fail, resulting in:

A → B → A → B → ...

while the payload changes slightly on every round.


Additional information

Disabling clipboard sharing stops the problem.

Keyboard/mouse sharing continues to work normally.

I can provide additional debug/trace logs or test a patched build if needed.

Log output

Show log

ceylon
[2026-09-08T08:40:22.107] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 0
[2026-09-08T08:40:22.111] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 1

[2026-09-08T08:40:23.106] INFO: screen "yansenwangdeMacBook-Pro.local" grabbed clipboard 0 from "yansenwangdeMacBook-Pro.local"
[2026-09-08T08:40:23.108] INFO: screen "yansenwangdeMacBook-Pro.local" grabbed clipboard 1 from "yansenwangdeMacBook-Pro.local"
[2026-09-08T08:40:23.109] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 0
[2026-09-08T08:40:23.110] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 1

[2026-09-08T08:40:24.320] INFO: screen "yansenwangdeMacBook-Pro.local" grabbed clipboard 0 from "yansenwangdeMacBook-Pro.local"
[2026-09-08T08:40:24.321] INFO: screen "yansenwangdeMacBook-Pro.local" grabbed clipboard 1 from "yansenwangdeMacBook-Pro.local"
[2026-09-08T08:40:24.323] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 0
[2026-09-08T08:40:24.323] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 1

[2026-09-08T08:40:25.328] INFO: screen "yansenwangdeMacBook-Pro.local" grabbed clipboard 0 from "yansenwangdeMacBook-Pro.local"
[2026-09-08T08:40:25.329] INFO: screen "yansenwangdeMacBook-Pro.local" grabbed clipboard 1 from "yansenwangdeMacBook-Pro.local"
[2026-09-08T08:40:25.330] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 0
[2026-09-08T08:40:25.330] INFO: screen "yansenwangdeMacBook-Pro.local" updated clipboard 1

Additional information

No response