Modified: trunk/dports/sysutils/synergy/Portfile (91514 => 91515)
--- trunk/dports/sysutils/synergy/Portfile 2012-04-03 23:34:17 UTC (rev 91514)
+++ trunk/dports/sysutils/synergy/Portfile 2012-04-03 23:46:39 UTC (rev 91515)
@@ -5,6 +5,7 @@
name synergy
version 1.3.8
+revision 1
categories sysutils
license GPL-2
platforms darwin
@@ -32,6 +33,9 @@
patchfiles-append patch-bug57-keypress.diff \
patch-bug57-modifiers.diff
+# See http://synergy-foss.org/tracker/issues/2962
+patchfiles-append patch-bug2962-clipboard.diff
+
post-patch {
# Set default config path
reinplace "s|@@SYSCONFDIR@@|${prefix}/etc/${name}|g" ${worksrcpath}/src/lib/arch/CArchFileUnix.cpp
Added: trunk/dports/sysutils/synergy/files/patch-bug2962-clipboard.diff (0 => 91515)
--- trunk/dports/sysutils/synergy/files/patch-bug2962-clipboard.diff (rev 0)
+++ trunk/dports/sysutils/synergy/files/patch-bug2962-clipboard.diff 2012-04-03 23:46:39 UTC (rev 91515)
@@ -0,0 +1,28 @@
+--- src/lib/platform/COSXClipboard.cpp.orig (revision 1169)
++++ src/lib/platform/COSXClipboard.cpp (revision 1170)
+@@ -87,6 +87,7 @@
+ void
+ COSXClipboard::add(EFormat format, const CString & data)
+ {
++ bool emptied = false;
+ if (m_pboard == NULL)
+ return;
+
+@@ -105,9 +106,14 @@
+
+ // integ tests showed that if you call add(...) twice, then the
+ // second call will actually fail to set clipboard data. calling
+- // empty() seems to solve this problem.
+- empty();
+-
++ // empty() seems to solve this problem. but, only clear the clipboard
++ // for the first converter, otherwise further converters will wipe out
++ // what we just added.
++ if (!emptied) {
++ empty();
++ emptied = true;
++ }
++
+ PasteboardPutItemFlavor(
+ m_pboard,
+ (PasteboardItemID) 0,