[xorg-commit-diffs] xc/programs/Xserver/hw/xwin winclipboardxevents.c, 1.1.4.1.2.17, 1.1.4.1.2.18

Harold L Hunt II xorg-commit at pdx.freedesktop.org
Thu Apr 1 10:35:11 PST 2004


Committed by: harold

Update of /cvs/xorg/xc/programs/Xserver/hw/xwin
In directory pdx:/tmp/cvs-serv7809

Modified Files:
      Tag: CYGWIN
	winclipboardxevents.c 
Log Message:
Pass the correct item count to XChangeProperty for handling the TARGETS type of selection.  (Lev Bishop)

Index: winclipboardxevents.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/hw/xwin/winclipboardxevents.c,v
retrieving revision 1.1.4.1.2.17
retrieving revision 1.1.4.1.2.18
diff -u -d -r1.1.4.1.2.17 -r1.1.4.1.2.18
--- a/winclipboardxevents.c	1 Apr 2004 18:20:19 -0000	1.1.4.1.2.17
+++ b/winclipboardxevents.c	1 Apr 2004 18:35:09 -0000	1.1.4.1.2.18
@@ -119,10 +119,10 @@
 	  /* Handle targets type of request */
 	  if (event.xselectionrequest.target == atomTargets)
 	    {
-	      Atom atomTargetArr[4] = {atomTargets,
-				       atomCompoundText,
-				       atomUTF8String,
-				       XA_STRING};
+	      Atom atomTargetArr[] = {atomTargets,
+				      atomCompoundText,
+				      atomUTF8String,
+				      XA_STRING};
 
 	      /* Try to change the property */
 	      iReturn = XChangeProperty (pDisplay,
@@ -132,7 +132,8 @@
 					 sizeof (atomTargetArr[0]),
 					 PropModeReplace,
 					 (unsigned char *) atomTargetArr,
-					 sizeof (atomTargetArr));
+					 (sizeof (atomTargetArr)
+					  / sizeof (atomTargetArr[0])));
 	      if (iReturn == BadAlloc
 		  || iReturn == BadAtom
 		  || iReturn == BadMatch




More information about the xorg-commit-diffs mailing list