[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

xorg-server: Changes to 'ubuntu'



 Xext/sync.c                                                         |   51 +++-
 Xi/exevents.c                                                       |   10 
 acinclude.m4                                                        |    2 
 configure.ac                                                        |   16 -
 debian/changelog                                                    |    5 
 debian/patches/150_dont-update-vcp-valuators.patch                  |   43 ---
 debian/patches/151_allow-null-as-rulesfile.patch                    |   68 -----
 debian/patches/series                                               |    4 
 glx/dispatch.h                                                      |    2 
 glx/glapi.h                                                         |   17 +
 glx/glapitable.h                                                    |    1 
 glx/glthread.c                                                      |    1 
 glx/indirect_dispatch.c                                             |   11 
 glx/indirect_dispatch_swap.c                                        |   11 
 glx/indirect_reqsize.c                                              |    3 
 hw/xfree86/common/xf86Xinput.c                                      |    4 
 hw/xfree86/modes/xf86Crtc.c                                         |    2 
 hw/xfree86/os-support/bsd/bsd_init.c                                |   88 ++++---
 hw/xfree86/ramdac/xf86Cursor.c                                      |    3 
 hw/xquartz/Makefile.am                                              |    3 
 hw/xquartz/X11Application.m                                         |    7 
 hw/xquartz/X11Controller.m                                          |  122 +++++-----
 hw/xquartz/bundle/Info.plist                                        |   39 ---
 hw/xquartz/bundle/Info.plist.cpp                                    |   39 +++
 hw/xquartz/bundle/Makefile.am                                       |   16 +
 hw/xquartz/bundle/Resources/English.lproj/main.nib/designable.nib   |   68 ++---
 hw/xquartz/bundle/Resources/English.lproj/main.nib/keyedobjects.nib |binary
 hw/xquartz/bundle/X11.sh                                            |    3 
 hw/xquartz/bundle/cpprules.in                                       |   37 +++
 hw/xquartz/bundle/mk_bundke.sh                                      |    3 
 hw/xquartz/darwin.c                                                 |    6 
 hw/xquartz/darwinEvents.c                                           |   35 +-
 hw/xquartz/mach-startup/Makefile.am                                 |    2 
 hw/xquartz/mach-startup/bundle-main.c                               |  111 ++++++---
 hw/xquartz/pbproxy/Makefile.am                                      |    4 
 randr/randr.c                                                       |    3 
 randr/randrstr.h                                                    |    8 
 randr/rrdispatch.c                                                  |    2 
 randr/rroutput.c                                                    |  112 +++++++++
 randr/rrscreen.c                                                    |   17 +
 randr/rrsdispatch.c                                                 |   27 ++
 randr/rrxinerama.c                                                  |   48 ++-
 xkb/xkbInit.c                                                       |   29 +-
 43 files changed, 678 insertions(+), 405 deletions(-)

New commits:
commit 50aea556192310b0d4bf93b2e17585f099652955
Author: Timo Aaltonen <tjaalton@cc.hut.fi>
Date:   Wed Dec 31 12:00:15 2008 +0200

    Remove patches 150, 151, applied upstream.

diff --git a/debian/changelog b/debian/changelog
index e7a1b46..6dddd67 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,7 @@ xorg-server (2:1.5.99.3-0ubuntu4) UNRELEASED; urgency=low
   * Disable patch 107 for now, to see what kind of a performance hit 
     it'll be. The problem it causes is random garbage on windows
     while apps are being loaded.
+  * Remove patches 150, 151, applied upstream.
 
  -- Timo Aaltonen <tjaalton@ubuntu.com>  Wed, 17 Dec 2008 15:02:53 +0200
 
diff --git a/debian/patches/150_dont-update-vcp-valuators.patch b/debian/patches/150_dont-update-vcp-valuators.patch
deleted file mode 100644
index 9899d06..0000000
--- a/debian/patches/150_dont-update-vcp-valuators.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-The VCP doesn't need to update the valuators anyway since it cannot send XI
-events. Just skip that bit.
-
-X.Org Bug 18882 <http://bugs.freedesktop.org/show_bug.cgi?id=18882>
----
-Not cherry-picked from master as master does need to update the valuators.
-(Keith: sorry for the resend, wrong "From:" blocked deliver to the xorg list)
-
- Xi/exevents.c |    8 ++++++--
- 1 files changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/Xi/exevents.c b/Xi/exevents.c
-index 00a6b21..8eef400 100644
---- a/Xi/exevents.c
-+++ b/Xi/exevents.c
-@@ -781,12 +781,14 @@ UpdateDeviceState(DeviceIntPtr device, xEvent* xE, int count)
-     }
- 
-     /* Update device axis */
--    for (i = 1; i < count; i++) {
-+    /* Don't update valuators for the VCP, it never sends XI events anyway */
-+    for (i = 1; !device->isMaster && i < count; i++) {
- 	if ((++xV)->type == DeviceValuator) {
- 	    int *axisvals;
-             int first = xV->first_valuator;
-             BOOL change = FALSE;
- 
-+
- 	    if (xV->num_valuators &&
-                 (!v || (xV->num_valuators &&
-                       (first + xV->num_valuators > v->numAxes))))
-@@ -1009,7 +1011,9 @@ ProcessOtherEvent(xEventPtr xE, DeviceIntPtr device, int count)
-     }
- 
-     /* Valuator event handling */
--    for (i = 1; i < count; i++) {
-+    /* Don't care about valuators for the VCP, it never sends XI events */
-+
-+    for (i = 1; !device->isMaster && i < count; i++) {
- 	if ((++xV)->type == DeviceValuator) {
- 	    int first = xV->first_valuator;
- 	    if (xV->num_valuators
-
diff --git a/debian/patches/151_allow-null-as-rulesfile.patch b/debian/patches/151_allow-null-as-rulesfile.patch
deleted file mode 100644
index 5a2d4ad..0000000
--- a/debian/patches/151_allow-null-as-rulesfile.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 7ef9f6ba03ddb40db1b1d1cba4153db3f6b81b4e Mon Sep 17 00:00:00 2001
-From: Peter Hutterer <peter.hutterer@redhat.com>
-Date: Wed, 3 Dec 2008 15:06:37 +1000
-Subject: [PATCH] xkb: Allow NULL as rulesFile in XkbSetRulesDflts.
-
-If no rules file is given, simply re-use the previous one. If no RF is given
-the first time this function is called, use the built-in default.
-This includes fixing the built-in default to something that actually exists.
-
-Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
----
- xkb/xkbInit.c |   29 ++++++++++++++++++++++++-----
- 1 files changed, 24 insertions(+), 5 deletions(-)
-
-diff --git a/xkb/xkbInit.c b/xkb/xkbInit.c
-index 0b93e87..3a0e375 100644
---- a/xkb/xkbInit.c
-+++ b/xkb/xkbInit.c
-@@ -93,7 +93,7 @@ typedef struct	_SrvXkmInfo {
- #define	XKB_BIN_DIRECTORY	XKB_BASE_DIRECTORY
- #endif
- #ifndef XKB_DFLT_RULES_FILE
--#define	XKB_DFLT_RULES_FILE	"rules"
-+#define	XKB_DFLT_RULES_FILE	"base"
- #endif
- #ifndef XKB_DFLT_KB_LAYOUT
- #define	XKB_DFLT_KB_LAYOUT	"us"
-@@ -240,14 +240,33 @@ XkbSetRulesUsed(XkbRF_VarDefsPtr defs)
-     return;
- }
- 
-+/**
-+ * Set the default RMLVO for the next device to be initialised.
-+ * If a parameter is NULL, the previous setting will be used. Use empty
-+ * strings if you want to delete a previous setting.
-+ *
-+ * If @rulesFile is NULL and no previous @rulesFile has been set, the
-+ * built-in default is chosen as default.
-+ */
- _X_EXPORT void
- XkbSetRulesDflts(char *rulesFile,char *model,char *layout,
- 					char *variant,char *options)
- {
--    if (XkbRulesFile)
--	_XkbFree(XkbRulesFile);
--    XkbRulesFile= _XkbDupString(rulesFile);
--    rulesDefined= True;
-+    if (!rulesFile && !XkbRulesFile)
-+    {
-+	LogMessage(X_WARNING, "[xkb] No rule given, and no previous rule "
-+		              "defined. Defaulting to '%s'.\n",
-+                              XKB_DFLT_RULES_FILE);
-+	rulesFile = XKB_DFLT_RULES_FILE;
-+    }
-+
-+    if (rulesFile) {
-+	if (XkbRulesFile)
-+	    _XkbFree(XkbRulesFile);
-+	XkbRulesFile= _XkbDupString(rulesFile);
-+	rulesDefined= True;
-+    }
-+
-     if (model) {
- 	if (XkbModelDflt)
- 	    _XkbFree(XkbModelDflt);
--- 
-1.6.0.4
-
diff --git a/debian/patches/series b/debian/patches/series
index 915f80f..ce40c3d 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -11,8 +11,6 @@
 135_rethrow_signals.patch
 140_quell_acpi_errmsgs.patch
 143_default_to_vesa.patch
-150_dont-update-vcp-valuators.patch
-151_allow-null-as-rulesfile.patch
 152_let-the-ddx-decide-on-the-xkbrulesdefaults.patch
 153_make_dmx_compile.patch
 154_force-copykeyclass-for-key-events.patch

commit e0df85b52b059b2202305faf99ab7f6e8ac0b747
Author: Timo Aaltonen <tjaalton@cc.hut.fi>
Date:   Wed Dec 31 11:09:45 2008 +0200

    Disable patch 107 for now.

diff --git a/debian/changelog b/debian/changelog
index c12ce09..e7a1b46 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,9 @@ xorg-server (2:1.5.99.3-0ubuntu4) UNRELEASED; urgency=low
 
   * debian/rules: Enable dbus-support.
   * Merge current server-1.6-branch.
+  * Disable patch 107 for now, to see what kind of a performance hit 
+    it'll be. The problem it causes is random garbage on windows
+    while apps are being loaded.
 
  -- Timo Aaltonen <tjaalton@ubuntu.com>  Wed, 17 Dec 2008 15:02:53 +0200
 
diff --git a/debian/patches/series b/debian/patches/series
index 907ec23..915f80f 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,7 +5,7 @@
 101_fedora_xserver-1.3.0-document-fontpath-correctly.patch
 102_ubuntu_sharevts_load_cpu.patch
 103_psb_auto.patch
-107_fedora_dont_backfill_bg_none.patch
+#107_fedora_dont_backfill_bg_none.patch
 110_fedora_no_move_damage.patch
 121_only_switch_vt_when_active.diff
 135_rethrow_signals.patch

commit bce31c9b8828a708abaf44e50f5482bd7a639fab
Author: Timo Aaltonen <tjaalton@cc.hut.fi>
Date:   Wed Dec 31 11:07:24 2008 +0200

    Update the changelog to reflect the merge.

diff --git a/debian/changelog b/debian/changelog
index 576a64f..c12ce09 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
 xorg-server (2:1.5.99.3-0ubuntu4) UNRELEASED; urgency=low
 
   * debian/rules: Enable dbus-support.
+  * Merge current server-1.6-branch.
 
  -- Timo Aaltonen <tjaalton@ubuntu.com>  Wed, 17 Dec 2008 15:02:53 +0200
 

commit 32e81074b967716865aef08b66ec29caf0fec2c5
Author: Robert Noland <rnoland@2hip.net>
Date:   Tue Dec 16 00:07:42 2008 -0500

    Support -sharevts on FreeBSD
    
    Bugzilla #11179
    
    Submitted-by: Nathan Whitehorn
    
    Signed-off-by: Robert Noland <rnoland@2hip.net>
    (cherry picked from commit 7aa29b9d66c3cd0f8af4fafbe92efd0c0556d225)

diff --git a/hw/xfree86/os-support/bsd/bsd_init.c b/hw/xfree86/os-support/bsd/bsd_init.c
index cbb9e48..7698084 100644
--- a/hw/xfree86/os-support/bsd/bsd_init.c
+++ b/hw/xfree86/os-support/bsd/bsd_init.c
@@ -45,6 +45,7 @@ static int devConsoleFd = -1;
 #if defined (SYSCONS_SUPPORT) || defined (PCVT_SUPPORT)
 static int VTnum = -1;
 static int initialVT = -1;
+static Bool ShareVTs = FALSE;
 #endif
 
 #ifdef PCCONS_SUPPORT
@@ -269,44 +270,48 @@ xf86OpenConsole()
 	    }
 #endif
 acquire_vt:
-	    /*
-	     * now get the VT
-	     */
-	    SYSCALL(result =
-		    ioctl(xf86Info.consoleFd, VT_ACTIVATE, xf86Info.vtno));
-	    if (result != 0)
-	    {
-    	        xf86Msg(X_WARNING, "xf86OpenConsole: VT_ACTIVATE failed\n");
-	    }
-	    SYSCALL(result =
+	    if (!ShareVTs) {
+		    /*
+		     * now get the VT
+		     */
+		    SYSCALL(result =
+			    ioctl(xf86Info.consoleFd, VT_ACTIVATE, xf86Info.vtno));
+		    if (result != 0)
+		    {
+			xf86Msg(X_WARNING, "xf86OpenConsole: VT_ACTIVATE failed\n");
+		    }
+		    SYSCALL(result =
 		    ioctl(xf86Info.consoleFd, VT_WAITACTIVE, xf86Info.vtno));
-	    if (result != 0)
-	    {
-	        xf86Msg(X_WARNING, "xf86OpenConsole: VT_WAITACTIVE failed\n");
-	    }
+		    if (result != 0)
+		    {
+			xf86Msg(X_WARNING, "xf86OpenConsole: VT_WAITACTIVE failed\n");
+		    }
 
-	    signal(SIGUSR1, xf86VTRequest);
+		    signal(SIGUSR1, xf86VTRequest);
 
-	    vtmode.mode = VT_PROCESS;
-	    vtmode.relsig = SIGUSR1;
-	    vtmode.acqsig = SIGUSR1;
-	    vtmode.frsig = SIGUSR1;
-	    if (ioctl(xf86Info.consoleFd, VT_SETMODE, &vtmode) < 0) 
-	    {
-	        FatalError("xf86OpenConsole: VT_SETMODE VT_PROCESS failed");
-	    }
-#if !defined(USE_DEV_IO) && !defined(USE_I386_IOPL)
-	    if (ioctl(xf86Info.consoleFd, KDENABIO, 0) < 0)
-	    {
-	        FatalError("xf86OpenConsole: KDENABIO failed (%s)",
-		           strerror(errno));
-	    }
-#endif
-	    if (ioctl(xf86Info.consoleFd, KDSETMODE, KD_GRAPHICS) < 0)
-	    {
-	        FatalError("xf86OpenConsole: KDSETMODE KD_GRAPHICS failed");
-	    }
-   	    break; 
+		    vtmode.mode = VT_PROCESS;
+		    vtmode.relsig = SIGUSR1;
+		    vtmode.acqsig = SIGUSR1;
+		    vtmode.frsig = SIGUSR1;
+		    if (ioctl(xf86Info.consoleFd, VT_SETMODE, &vtmode) < 0) 
+		    {
+			FatalError("xf86OpenConsole: VT_SETMODE VT_PROCESS failed");
+		    }
+	#if !defined(USE_DEV_IO) && !defined(USE_I386_IOPL)
+		    if (ioctl(xf86Info.consoleFd, KDENABIO, 0) < 0)
+		    {
+			FatalError("xf86OpenConsole: KDENABIO failed (%s)",
+				   strerror(errno));
+		    }
+	#endif
+		    if (ioctl(xf86Info.consoleFd, KDSETMODE, KD_GRAPHICS) < 0)
+		    {
+			FatalError("xf86OpenConsole: KDSETMODE KD_GRAPHICS failed");
+		    }
+	    } else { /* ShareVTs */
+		    close(xf86Info.consoleFd);
+	    }	
+  	    break; 
 #endif /* SYSCONS_SUPPORT || PCVT_SUPPORT */
 #ifdef WSCONS_SUPPORT
 	case WSCONS:
@@ -319,7 +324,7 @@ acquire_vt:
     {
 	/* serverGeneration != 1 */
 #if defined (SYSCONS_SUPPORT) || defined (PCVT_SUPPORT)
-    	if (xf86Info.consType == SYSCONS || xf86Info.consType == PCVT)
+    	if (!ShareVTs) if (xf86Info.consType == SYSCONS || xf86Info.consType == PCVT)
     	{
 	    if (ioctl(xf86Info.consoleFd, VT_ACTIVATE, xf86Info.vtno) != 0)
 	    {
@@ -392,6 +397,9 @@ xf86OpenSyscons()
 	    if (ioctl(fd, VT_GETACTIVE, &initialVT) < 0)
 		initialVT = -1;
 #endif
+            if (ShareVTs)
+		xf86Info.vtno = initialVT;
+
 	    if (xf86Info.vtno == -1)
 	    {
 		/*
@@ -651,6 +659,8 @@ xf86CloseConsole()
     struct vt_mode   VT;
 #endif
 
+    if (ShareVTs) return;
+
     switch (xf86Info.consType)
     {
 #ifdef PCCONS_SUPPORT
@@ -717,6 +727,11 @@ xf86ProcessArgument(int argc, char *argv[], int i)
 		return(1);
 	}
 #if defined (SYSCONS_SUPPORT) || defined (PCVT_SUPPORT)
+	if (!strcmp(argv[i], "-sharevts"))
+	{	
+		ShareVTs = TRUE;
+		return(1);
+	}
 	if ((argv[i][0] == 'v') && (argv[i][1] == 't'))
 	{
 		if (sscanf(argv[i], "vt%2d", &VTnum) == 0 ||
@@ -737,6 +752,7 @@ xf86UseMsg()
 {
 #if defined (SYSCONS_SUPPORT) || defined (PCVT_SUPPORT)
 	ErrorF("vtXX                   use the specified VT number (1-12)\n");
+	ErrorF("-sharevts              share VTs with another X server\n");
 #endif /* SYSCONS_SUPPORT || PCVT_SUPPORT */
 	ErrorF("-keeptty               ");
 	ErrorF("don't detach controlling tty (for debugging only)\n");

commit 4c68079c2ae8a2f04363623c44d17bc8c255c3bf
Author: Ian Romanick <ian.d.romanick@intel.com>
Date:   Sun Dec 14 18:58:33 2008 -0800

    GLX: Changes resulting from changes to Mesa generator scripts / data
    
    Several recent Mesa commits (listed below) make modifications to the
    protocol generator data and scripts.  This commit represents the
    changes to the generated files resulting from the previous changes.
    
        - 0f73302d24f4201813da2939742c5bcb6964b3b1
          GLX: Fix protocol for glTexSubImage#D
    
        - 1709ab01ef24279c782e420568e9257b4b92b224
          Return 0 as the request size when the pixels parameter is NULL
    
        - 63cca2ba10ce7dcc8481cfa4be3872dfc269dded
          GLX: Include glapi.h before glapitable.h
    
    This is the server-side part of the fix for bugzilla #11003.
    (cherry picked from commit f1c9b5ab230cbb4124d8d476ae4886d05022adcb)

diff --git a/glx/dispatch.h b/glx/dispatch.h
index 7123156..f019aa6 100644
--- a/glx/dispatch.h
+++ b/glx/dispatch.h
@@ -28,6 +28,8 @@
 #if !defined( _DISPATCH_H_ )
 #  define _DISPATCH_H_
 
+
+#include "glapitable.h"
 /**
  * \file dispatch.h
  * Macros for handling GL dispatch tables.
diff --git a/glx/glapi.h b/glx/glapi.h
index ddfb1cf..8f2cf66 100644
--- a/glx/glapi.h
+++ b/glx/glapi.h
@@ -1,8 +1,8 @@
 /*
  * Mesa 3-D graphics library
- * Version:  6.5
+ * Version:  7.1
  *
- * Copyright (C) 1999-2006  Brian Paul   All Rights Reserved.
+ * Copyright (C) 1999-2008  Brian Paul   All Rights Reserved.
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
  * copy of this software and associated documentation files (the "Software"),
@@ -44,12 +44,17 @@
 #ifndef _GLAPI_H
 #define _GLAPI_H
 
+#define GL_GLEXT_PROTOTYPES
 
 #include "GL/gl.h"
-#include "glapitable.h"
+#include "GL/glext.h"
 #include "glthread.h"
 
 
+struct _glapi_table;
+
+typedef void (*_glapi_proc)(void); /* generic function pointer */
+
 typedef void (*_glapi_warning_func)(void *ctx, const char *str, ...);
 
 
@@ -63,6 +68,12 @@ typedef void (*_glapi_warning_func)(void *ctx, const char *str, ...);
 #endif
 
 
+/*
+ * Number of extension functions which we can dynamically add at runtime.
+ */
+#define MAX_EXTENSION_FUNCS 300
+
+
 /**
  ** Define the GET_CURRENT_CONTEXT() macro.
  ** \param C local variable which will hold the current context.
diff --git a/glx/glapitable.h b/glx/glapitable.h
index 48941f5..5d9d40a 100644
--- a/glx/glapitable.h
+++ b/glx/glapitable.h
@@ -37,7 +37,6 @@
 # define GLAPIENTRYP GLAPIENTRY *
 #endif
 
-typedef void (*_glapi_proc)(void); /* generic function pointer */
 
 struct _glapi_table
 {
diff --git a/glx/glthread.c b/glx/glthread.c
index 813d6f9..b818f4e 100644
--- a/glx/glthread.c
+++ b/glx/glthread.c
@@ -34,6 +34,7 @@
 #endif
 
 #include <stdlib.h>
+#include <stdio.h>
 #include "glthread.h"
 
 
diff --git a/glx/indirect_dispatch.c b/glx/indirect_dispatch.c
index 2afd3eb..6547f5d 100644
--- a/glx/indirect_dispatch.c
+++ b/glx/indirect_dispatch.c
@@ -36,8 +36,8 @@
 #include "glxbyteorder.h"
 #include "indirect_util.h"
 #include "singlesize.h"
-#include "glapitable.h"
 #include "glapi.h"
+#include "glapitable.h"
 #include "glthread.h"
 #include "dispatch.h"
 
@@ -2972,8 +2972,7 @@ void __glXDisp_PrioritizeTextures(GLbyte * pc)
 
 void __glXDisp_TexSubImage1D(GLbyte * pc)
 {
-    const CARD32 ptr_is_null = *(CARD32 *)(pc + 52);
-    const GLvoid * const pixels = (const GLvoid *) (ptr_is_null != 0) ? NULL : (pc + 56);
+    const GLvoid * const pixels = (const GLvoid *) (pc + 56);
     __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc);
 
     CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES,   hdr->swapBytes) );
@@ -2996,8 +2995,7 @@ void __glXDisp_TexSubImage1D(GLbyte * pc)
 
 void __glXDisp_TexSubImage2D(GLbyte * pc)
 {
-    const CARD32 ptr_is_null = *(CARD32 *)(pc + 52);
-    const GLvoid * const pixels = (const GLvoid *) (ptr_is_null != 0) ? NULL : (pc + 56);
+    const GLvoid * const pixels = (const GLvoid *) (pc + 56);
     __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc);
 
     CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES,   hdr->swapBytes) );
@@ -3773,8 +3771,7 @@ void __glXDisp_TexImage3D(GLbyte * pc)
 
 void __glXDisp_TexSubImage3D(GLbyte * pc)
 {
-    const CARD32 ptr_is_null = *(CARD32 *)(pc + 84);
-    const GLvoid * const pixels = (const GLvoid *) (ptr_is_null != 0) ? NULL : (pc + 88);
+    const GLvoid * const pixels = (const GLvoid *) (pc + 88);
     __GLXpixel3DHeader * const hdr = (__GLXpixel3DHeader *)(pc);
 
     CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES,   hdr->swapBytes) );
diff --git a/glx/indirect_dispatch_swap.c b/glx/indirect_dispatch_swap.c
index f137cbe..0b8c27c 100644
--- a/glx/indirect_dispatch_swap.c
+++ b/glx/indirect_dispatch_swap.c
@@ -36,8 +36,8 @@
 #include "glxbyteorder.h"
 #include "indirect_util.h"
 #include "singlesize.h"
-#include "glapitable.h"
 #include "glapi.h"
+#include "glapitable.h"
 #include "glthread.h"
 #include "dispatch.h"
 
@@ -3092,8 +3092,7 @@ void __glXDispSwap_PrioritizeTextures(GLbyte * pc)
 
 void __glXDispSwap_TexSubImage1D(GLbyte * pc)
 {
-    const CARD32 ptr_is_null = *(CARD32 *)(pc + 52);
-    const GLvoid * const pixels = (const GLvoid *) (ptr_is_null != 0) ? NULL : (pc + 56);
+    const GLvoid * const pixels = (const GLvoid *) (pc + 56);
     __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc);
 
     CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES,   hdr->swapBytes) );
@@ -3116,8 +3115,7 @@ void __glXDispSwap_TexSubImage1D(GLbyte * pc)
 
 void __glXDispSwap_TexSubImage2D(GLbyte * pc)
 {
-    const CARD32 ptr_is_null = *(CARD32 *)(pc + 52);
-    const GLvoid * const pixels = (const GLvoid *) (ptr_is_null != 0) ? NULL : (pc + 56);
+    const GLvoid * const pixels = (const GLvoid *) (pc + 56);
     __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc);
 
     CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES,   hdr->swapBytes) );
@@ -3909,8 +3907,7 @@ void __glXDispSwap_TexImage3D(GLbyte * pc)
 
 void __glXDispSwap_TexSubImage3D(GLbyte * pc)
 {
-    const CARD32 ptr_is_null = *(CARD32 *)(pc + 84);
-    const GLvoid * const pixels = (const GLvoid *) (ptr_is_null != 0) ? NULL : (pc + 88);
+    const GLvoid * const pixels = (const GLvoid *) (pc + 88);
     __GLXpixel3DHeader * const hdr = (__GLXpixel3DHeader *)(pc);
 
     CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES,   hdr->swapBytes) );
diff --git a/glx/indirect_reqsize.c b/glx/indirect_reqsize.c
index 954eecd..c47f01e 100644
--- a/glx/indirect_reqsize.c
+++ b/glx/indirect_reqsize.c
@@ -572,6 +572,9 @@ __glXTexImage3DReqSize(const GLbyte *pc, Bool swap)
         type = bswap_32(type);
     }
 
+    if (*(CARD32 *) (pc + 76))
+        return 0;
+
     return __glXImageSize(format, type, target, width, height, depth,
                           image_height, row_length, skip_images,
                           skip_rows, alignment);

commit 75bad86992338f5ce0ade6986b758cd6af2a5b9a
Author: Cooper Yuan <Cooper.Yuan@amd.com>
Date:   Mon Dec 15 10:29:34 2008 -0500

    Fix typo in xf86PickCrtcs()
    (cherry picked from commit 2a61397d17339113b9e37995b06ca543589814ce)

diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index 78105b6..b972974 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -976,7 +976,7 @@ xf86PickCrtcs (ScrnInfoPtr	scrn,
 	     * see if they can be cloned
 	     */
 	    if (xf86ModesEqual (modes[o], modes[n]) &&
-		config->output[0]->initial_rotation == config->output[n]->initial_rotation &&
+		config->output[o]->initial_rotation == config->output[n]->initial_rotation &&
 		config->output[o]->initial_x == config->output[n]->initial_x &&
 		config->output[o]->initial_y == config->output[n]->initial_y)
 	    {

commit f427d3aaa7ca58822033ac5486b46671a937b68a
Author: Jeremy Huddleston <jeremyhu@freedesktop.org>
Date:   Sat Dec 13 00:45:27 2008 -0800

    XQuartz: Updated menu item ordering for better HIG compliance
    (cherry picked from commit 4c9bb241ce5fb856fab20ae96fa89bd2b71ef242)
    (cherry picked from commit 73987010b2ef9c67b6614e226c6fae65d834d8f3)

diff --git a/hw/xquartz/bundle/Resources/English.lproj/main.nib/designable.nib b/hw/xquartz/bundle/Resources/English.lproj/main.nib/designable.nib
index 1ed46e9..d271625 100644
--- a/hw/xquartz/bundle/Resources/English.lproj/main.nib/designable.nib
+++ b/hw/xquartz/bundle/Resources/English.lproj/main.nib/designable.nib
@@ -1,11 +1,11 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.02">
+<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.03">
 	<data>
 		<int key="IBDocument.SystemTarget">1050</int>
-		<string key="IBDocument.SystemVersion">9F33</string>
-		<string key="IBDocument.InterfaceBuilderVersion">672</string>
-		<string key="IBDocument.AppKitVersion">949.34</string>
-		<string key="IBDocument.HIToolboxVersion">352.00</string>
+		<string key="IBDocument.SystemVersion">9G55</string>
+		<string key="IBDocument.InterfaceBuilderVersion">677</string>
+		<string key="IBDocument.AppKitVersion">949.43</string>
+		<string key="IBDocument.HIToolboxVersion">353.00</string>
 		<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
 			<bool key="EncodedWithXMLCoder">YES</bool>
 		</object>
@@ -13,6 +13,15 @@
 			<bool key="EncodedWithXMLCoder">YES</bool>
 			<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
 		</object>
+		<object class="NSMutableDictionary" key="IBDocument.Metadata">
+			<bool key="EncodedWithXMLCoder">YES</bool>
+			<object class="NSArray" key="dict.sortedKeys">
+				<bool key="EncodedWithXMLCoder">YES</bool>
+			</object>
+			<object class="NSMutableArray" key="dict.values">
+				<bool key="EncodedWithXMLCoder">YES</bool>
+			</object>
+		</object>
 		<object class="NSMutableArray" key="IBDocument.RootObjects" id="904585544">
 			<bool key="EncodedWithXMLCoder">YES</bool>
 			<object class="NSCustomObject" id="815810918">
@@ -256,6 +265,15 @@
 							</object>
 							<object class="NSMutableArray" key="NSMenuItems">
 								<bool key="EncodedWithXMLCoder">YES</bool>
+								<object class="NSMenuItem" id="984461797">
+									<reference key="NSMenu" ref="96874957"/>
+									<string key="NSTitle">Close</string>
+									<string key="NSKeyEquiv">w</string>
+									<int key="NSKeyEquivModMask">1048576</int>
+									<int key="NSMnemonicLoc">2147483647</int>
+									<reference key="NSOnImage" ref="531645050"/>
+									<reference key="NSMixedImage" ref="351811234"/>
+								</object>
 								<object class="NSMenuItem" id="677652931">
 									<reference key="NSMenu" ref="96874957"/>
 									<string key="NSTitle">Minimize</string>
@@ -274,6 +292,17 @@
 									<reference key="NSOnImage" ref="531645050"/>
 									<reference key="NSMixedImage" ref="351811234"/>
 								</object>
+								<object class="NSMenuItem" id="280172320">
+									<reference key="NSMenu" ref="96874957"/>
+									<bool key="NSIsDisabled">YES</bool>
+									<bool key="NSIsSeparator">YES</bool>
+									<string key="NSTitle"/>
+									<string key="NSKeyEquiv"/>
+									<int key="NSKeyEquivModMask">1048576</int>
+									<int key="NSMnemonicLoc">2147483647</int>
+									<reference key="NSOnImage" ref="531645050"/>
+									<reference key="NSMixedImage" ref="351811234"/>
+								</object>
 								<object class="NSMenuItem" id="1036389925">
 									<reference key="NSMenu" ref="96874957"/>
 									<string key="NSTitle">Cycle Through Windows</string>
@@ -292,26 +321,6 @@
 									<reference key="NSOnImage" ref="531645050"/>
 									<reference key="NSMixedImage" ref="351811234"/>
 								</object>
-								<object class="NSMenuItem" id="280172320">
-									<reference key="NSMenu" ref="96874957"/>
-									<bool key="NSIsDisabled">YES</bool>
-									<bool key="NSIsSeparator">YES</bool>
-									<string key="NSTitle"/>
-									<string key="NSKeyEquiv"/>
-									<int key="NSKeyEquivModMask">1048576</int>
-									<int key="NSMnemonicLoc">2147483647</int>
-									<reference key="NSOnImage" ref="531645050"/>
-									<reference key="NSMixedImage" ref="351811234"/>
-								</object>
-								<object class="NSMenuItem" id="984461797">
-									<reference key="NSMenu" ref="96874957"/>
-									<string key="NSTitle">Close</string>
-									<string key="NSKeyEquiv">w</string>
-									<int key="NSKeyEquivModMask">1048576</int>
-									<int key="NSMnemonicLoc">2147483647</int>
-									<reference key="NSOnImage" ref="531645050"/>
-									<reference key="NSMixedImage" ref="351811234"/>
-								</object>
 								<object class="NSMenuItem" id="155085383">
 									<reference key="NSMenu" ref="96874957"/>
 									<bool key="NSIsDisabled">YES</bool>
@@ -1442,6 +1451,7 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 									</object>
 									<string key="NSFrame">{{1, 17}, {301, 198}}</string>
 									<reference key="NSSuperview" ref="1063387772"/>
+									<reference key="NSNextKeyView" ref="905092943"/>
 									<reference key="NSDocView" ref="905092943"/>
 									<reference key="NSBGColor" ref="812484075"/>
 									<int key="NScvFlags">4</int>
@@ -1474,6 +1484,7 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 									</object>
 									<string key="NSFrame">{{1, 0}, {301, 17}}</string>
 									<reference key="NSSuperview" ref="1063387772"/>
+									<reference key="NSNextKeyView" ref="792419186"/>
 									<reference key="NSDocView" ref="792419186"/>
 									<reference key="NSBGColor" ref="812484075"/>
 									<int key="NScvFlags">4</int>
@@ -1482,6 +1493,7 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 							</object>
 							<string key="NSFrame">{{20, 20}, {318, 231}}</string>
 							<reference key="NSSuperview" ref="85544634"/>
+							<reference key="NSNextKeyView" ref="580565898"/>
 							<int key="NSsFlags">50</int>
 							<reference key="NSVScroller" ref="842897584"/>
 							<reference key="NSHScroller" ref="17278747"/>
@@ -2195,11 +2207,11 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 							<reference ref="276216762"/>
 							<reference ref="1066447520"/>
 							<reference ref="1036389925"/>
-							<reference ref="280172320"/>
 							<reference ref="369641893"/>
-							<reference ref="984461797"/>
 							<reference ref="155085383"/>
 							<reference ref="444952046"/>
+							<reference ref="984461797"/>
+							<reference ref="280172320"/>
 						</object>
 						<reference key="parent" ref="931553638"/>
 					</object>
@@ -3626,7 +3638,7 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 					<reference ref="9"/>
 					<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
 					<reference ref="9"/>
-					<string>{{204, 683}, {315, 153}}</string>
+					<string>{{349, 858}, {315, 153}}</string>
 					<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
 					<reference ref="9"/>
 					<string>{{271, 666}, {301, 153}}</string>
@@ -3634,7 +3646,7 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 					<string>{{437, 749}, {484, 308}}</string>
 					<reference ref="9"/>
 					<string>{{184, 290}, {481, 345}}</string>
-					<integer value="0"/>
+					<integer value="0" id="8"/>
 					<reference ref="9"/>
 					<string>{3.40282e+38, 3.40282e+38}</string>
 					<string>{320, 240}</string>
@@ -3654,13 +3666,13 @@ d2hpY2ggbWF5IHByZXZlbnQgWDExIGFwcGxpY2F0aW9ucyBmcm9tIGxhdW5jaGluZy4</string>
 					<string>{{68, 585}, {454, 271}}</string>
 					<reference ref="9"/>
 					<string>{{433, 406}, {486, 327}}</string>
-					<integer value="0"/>
+					<reference ref="8"/>
 					<reference ref="9"/>
 					<string>{3.40282e+38, 3.40282e+38}</string>
 					<string>{320, 240}</string>
 					<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
 					<reference ref="9"/>
-					<string>{{8, 844}, {336, 20}}</string>
+					<string>{{145, 1011}, {336, 20}}</string>
 					<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
 					<reference ref="9"/>
 					<string>{{67, 819}, {336, 20}}</string>
diff --git a/hw/xquartz/bundle/Resources/English.lproj/main.nib/keyedobjects.nib b/hw/xquartz/bundle/Resources/English.lproj/main.nib/keyedobjects.nib
index 16c7109..ee6cdf2 100644
Binary files a/hw/xquartz/bundle/Resources/English.lproj/main.nib/keyedobjects.nib and b/hw/xquartz/bundle/Resources/English.lproj/main.nib/keyedobjects.nib differ

commit d0eb4337e3468a5854e4801fcb1d2bc7d5c4d81f
Author: Jeremy Huddleston <jeremyhu@freedesktop.org>
Date:   Wed Dec 10 23:04:30 2008 -0800

    XQuartz: Tiger fix, don't call Xplugin code in the Appkit thread if Xplugin isn't threadsafe.
    (cherry picked from commit 748d9e5bd756513d42c4046f3b31e1fdc55bccb6)
    (cherry picked from commit fd31984e0c0f9a37087cd1cffaa3ba116b12c2e5)

diff --git a/hw/xquartz/X11Application.m b/hw/xquartz/X11Application.m
index 371b6d6..2c6b60b 100644
--- a/hw/xquartz/X11Application.m
+++ b/hw/xquartz/X11Application.m
@@ -1008,6 +1008,9 @@ extern int darwin_modifier_flags; // darwinEvents.c
                 pDev = darwinTabletCurrent;
             }
 
+/* Older libXplugin (Tiger/"Stock" Leopard) aren't thread safe, so we can't call xp_find_window from the Appkit thread */
+#ifdef XPLUGIN_VERSION
+#if XPLUGIN_VERSION > 0
             if(!quartzServerVisible) {
                 xp_window_id wid;
 
@@ -1023,6 +1026,8 @@ extern int darwin_modifier_flags; // darwinEvents.c
                     wid == 0)
                     return;        
             }
+#endif
+#endif
             
             DarwinSendPointerEvents(pDev, ev_type, ev_button, pointer_x, pointer_y,
                                     pressure, tilt_x, tilt_y);

commit d9e1fdcd40bf12378c9fa05a8adbe3aefca65676
Author: Jeremy Huddleston <jeremyhu@freedesktop.org>
Date:   Wed Dec 10 01:56:01 2008 -0800

    XQuartz: Fix path to executable
    (cherry picked from commit 7e9d3698e070a0c63dd2556651373c3aca58e2fe)
    (cherry picked from commit 5926b213b39a90601c73f026dc0699723f5ed10d)

diff --git a/hw/xquartz/bundle/X11.sh b/hw/xquartz/bundle/X11.sh
index 5e00a82..2f953d1 100755
--- a/hw/xquartz/bundle/X11.sh
+++ b/hw/xquartz/bundle/X11.sh
@@ -1,3 +1,3 @@
 #!/bin/bash --login
 
-./X11 "${@}"
+"$(dirname $0)"/X11 "${@}"

commit e93daf4e7140115f9485c8c0cdc358d50c9575be
Author: Jeremy Huddleston <jeremyhu@freedesktop.org>
Date:   Wed Dec 10 00:00:29 2008 -0800

    XQuartz: fixed make dist
    (cherry picked from commit 2d52367ab92429e58596d1a1ed3ef52a0a38a7aa)
    (cherry picked from commit 13eff12902be1b25d0ccc2089e08305f88949f32)

diff --git a/hw/xquartz/bundle/Info.plist.cpp b/hw/xquartz/bundle/Info.plist.cpp
index 16434f2..9713289 100644
--- a/hw/xquartz/bundle/Info.plist.cpp
+++ b/hw/xquartz/bundle/Info.plist.cpp
@@ -5,7 +5,7 @@
 	<key>CFBundleDevelopmentRegion</key>
 		<string>English</string>
 	<key>CFBundleExecutable</key>
-		<string>X11</string>
+		<string>X11.sh</string>
 	<key>CFBundleGetInfoString</key>
 		<string>APPLE_APPLICATION_NAME</string>
 	<key>CFBundleIconFile</key>
diff --git a/hw/xquartz/bundle/Makefile.am b/hw/xquartz/bundle/Makefile.am
index e765d6e..03fa1dd 100644
--- a/hw/xquartz/bundle/Makefile.am
+++ b/hw/xquartz/bundle/Makefile.am
@@ -17,6 +17,7 @@ resource_DATA = Xquartz.plist
 
 EXTRA_DIST = \
 	mk_bundke.sh \
+	X11.sh \
 	Info.plist.cpp \
 	PkgInfo \
 	$(resource_DATA) \

commit 1cf76f23c7d210d75a401568c5ad788a2fd268d1
Author: Jeremy Huddleston <jeremyhu@freedesktop.org>
Date:   Tue Dec 9 23:47:32 2008 -0800

    XQuartz: Avoid using login /bin/sh blech.  Just use a bash script to start the app, so it will inherit the right environment
    (cherry picked from commit f4b7ad9cc6b0c99fc7ee8516c4bf858ece938148)
    (cherry picked from commit fdf64256127b2661bd6aa81ac694350028d36c43)

diff --git a/hw/xquartz/X11Controller.m b/hw/xquartz/X11Controller.m
index 67a80d3..7222f46 100644
--- a/hw/xquartz/X11Controller.m
+++ b/hw/xquartz/X11Controller.m
@@ -314,65 +314,79 @@ BOOL xquartz_resetenv_display = NO;
 
 - (void) launch_client:(NSString *)filename
 {
-  const char *command = [filename UTF8String];
-  const char *argv[7];
-  int child1, child2 = 0;
-  int status;
-	
-  argv[0] = "/usr/bin/login";
-  argv[1] = "-fp";
-  argv[2] = getlogin();
-  argv[3] = [X11App prefs_get_string:@PREFS_LOGIN_SHELL default:"/bin/sh"];
-  argv[4] = "-c";
-  argv[5] = command;
-  argv[6] = NULL;
-
-  /* Do the fork-twice trick to avoid having to reap zombies */
+    const char *command = [filename UTF8String];
+    int child1, child2 = 0;
+    int status;
+    char newcommand[1024];
+    char *newargv[1024];
+    char buf[128];
+    size_t newargc;
+    char *s;
     
-  child1 = fork();
+    if(strlen(command) > 1023) {
+        fprintf(stderr, "Error: command is too long: %s\n", command);
+        return;
+    }
+    
+    strlcpy(newcommand, command, 1024);
     
-  switch (child1) {
-  case -1:                                /* error */
-    break;
+    for(newargc=0, s=newcommand; *s; newargc++) {
+        for(; *s && *s == ' '; s++);
+        if(!*s)
+            break;
+        
+        newargv[newargc] = s;
+        for(; *s && *s != ' '; s++);
+        
+        if(*s) {
+            *s='\0';
+            s++;
+        }
+    }
+    newargv[newargc] = NULL;
+    
+    s = getenv("DISPLAY");
+    if (xquartz_resetenv_display || s == NULL || s[0] == 0) {
+        snprintf(buf, sizeof(buf), ":%s", display);
+        setenv("DISPLAY", buf, TRUE);
+    }
+
+    /* Do the fork-twice trick to avoid having to reap zombies */
+    child1 = fork();
+    switch (child1) {
+        case -1:                                /* error */
+            break;
       
-  case 0:                                 /* child1 */
-    child2 = fork();
+        case 0:                                 /* child1 */
+            child2 = fork();
       
-    switch (child2) {
-      int max_files, i;
-      char buf[1024], *temp;
-	
-    case -1:                            /* error */
-      _exit(1);
-	
-    case 0:                             /* child2 */
-      /* close all open files except for standard streams */
-      max_files = sysconf(_SC_OPEN_MAX);


Reply to: