aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/include
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-11-25 08:32:21 +0100
committermarha <marha@users.sourceforge.net>2011-11-25 08:32:21 +0100
commit849d328b25c2f3c87d539e1fe7af38e7580a0409 (patch)
tree349c425a87ddb3aaa1d7832d5a8e68252fc73ddb /xorg-server/include
parenta8a12d4c8be177f63cae7dc96c2b52f09e228a76 (diff)
parenta0b4a1330be6a36ad095222d2ea83927cd33514d (diff)
downloadvcxsrv-849d328b25c2f3c87d539e1fe7af38e7580a0409.tar.gz
vcxsrv-849d328b25c2f3c87d539e1fe7af38e7580a0409.tar.bz2
vcxsrv-849d328b25c2f3c87d539e1fe7af38e7580a0409.zip
Merge remote-tracking branch 'origin/released'
Conflicts: xorg-server/glx/glxdriswrast.c xorg-server/glx/single2.c xorg-server/hw/xwin/winconfig.c xorg-server/os/osinit.c xorg-server/os/xdmcp.c xorg-server/xkb/xkbInit.c
Diffstat (limited to 'xorg-server/include')
-rw-r--r--xorg-server/include/dix-config.h.in3
-rw-r--r--xorg-server/include/exevents.h2
-rw-r--r--xorg-server/include/extension.h4
-rw-r--r--xorg-server/include/extinit.h2
-rw-r--r--xorg-server/include/extnsionst.h224
-rw-r--r--xorg-server/include/input.h4
-rw-r--r--xorg-server/include/misc.h2
-rw-r--r--xorg-server/include/os.h10
-rw-r--r--xorg-server/include/xkbfile.h4
9 files changed, 131 insertions, 124 deletions
diff --git a/xorg-server/include/dix-config.h.in b/xorg-server/include/dix-config.h.in
index 7d6cb966c..e1d3a9eaa 100644
--- a/xorg-server/include/dix-config.h.in
+++ b/xorg-server/include/dix-config.h.in
@@ -190,6 +190,9 @@
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
+/* Define to 1 if you have the `strndup' function. */
+#undef HAVE_STRNDUP
+
/* Define to 1 if you have the `strrchr' function. */
#undef HAVE_STRRCHR
diff --git a/xorg-server/include/exevents.h b/xorg-server/include/exevents.h
index 720fb2e5a..12ea37885 100644
--- a/xorg-server/include/exevents.h
+++ b/xorg-server/include/exevents.h
@@ -126,7 +126,7 @@ extern _X_EXPORT void XIUnregisterPropertyHandler(
);
extern _X_EXPORT Atom XIGetKnownProperty(
- char* name
+ const char* name
);
extern _X_EXPORT DeviceIntPtr XIGetDevice(xEvent *ev);
diff --git a/xorg-server/include/extension.h b/xorg-server/include/extension.h
index 29a11c300..ee6260eb5 100644
--- a/xorg-server/include/extension.h
+++ b/xorg-server/include/extension.h
@@ -54,9 +54,9 @@ extern _X_EXPORT unsigned short StandardMinorOpcode(ClientPtr /*client*/);
extern _X_EXPORT unsigned short MinorOpcodeOfRequest(ClientPtr /*client*/);
-extern _X_EXPORT Bool EnableDisableExtension(char *name, Bool enable);
+extern _X_EXPORT Bool EnableDisableExtension(const char *name, Bool enable);
-extern _X_EXPORT void EnableDisableExtensionError(char *name, Bool enable);
+extern _X_EXPORT void EnableDisableExtensionError(const char *name, Bool enable);
extern _X_EXPORT void InitExtensions(int argc, char **argv);
diff --git a/xorg-server/include/extinit.h b/xorg-server/include/extinit.h
index c3aa7b681..8e47beb48 100644
--- a/xorg-server/include/extinit.h
+++ b/xorg-server/include/extinit.h
@@ -41,7 +41,7 @@ extern _X_EXPORT void
AssignTypeAndName (
DeviceIntPtr /* dev */,
Atom /* type */,
- char * /* name */
+ const char * /* name */
);
#endif /* EXTINIT_H */
diff --git a/xorg-server/include/extnsionst.h b/xorg-server/include/extnsionst.h
index 92790b38f..aeefa9918 100644
--- a/xorg-server/include/extnsionst.h
+++ b/xorg-server/include/extnsionst.h
@@ -1,112 +1,112 @@
-/***********************************************************
-
-Copyright 1987, 1998 The Open Group
-
-Permission to use, copy, modify, distribute, and sell this software and its
-documentation for any purpose is hereby granted without fee, provided that
-the above copyright notice appear in all copies and that both that
-copyright notice and this permission notice appear in supporting
-documentation.
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
-AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
-CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-Except as contained in this notice, the name of The Open Group shall not be
-used in advertising or otherwise to promote the sale, use or other dealings
-in this Software without prior written authorization from The Open Group.
-
-
-Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
-
- All Rights Reserved
-
-Permission to use, copy, modify, and distribute this software and its
-documentation for any purpose and without fee is hereby granted,
-provided that the above copyright notice appear in all copies and that
-both that copyright notice and this permission notice appear in
-supporting documentation, and that the name of Digital not be
-used in advertising or publicity pertaining to distribution of the
-software without specific, written prior permission.
-
-DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
-ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
-DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
-ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
-WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
-ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
-SOFTWARE.
-
-******************************************************************/
-
-#ifndef EXTENSIONSTRUCT_H
-#define EXTENSIONSTRUCT_H
-
-#include "dix.h"
-#include "misc.h"
-#include "screenint.h"
-#include "extension.h"
-#include "gc.h"
-#include "privates.h"
-
-typedef struct _ExtensionEntry {
- int index;
- void (* CloseDown)( /* called at server shutdown */
- struct _ExtensionEntry * /* extension */);
- char *name; /* extension name */
- int base; /* base request number */
- int eventBase;
- int eventLast;
- int errorBase;
- int errorLast;
- int num_aliases;
- char **aliases;
- pointer extPrivate;
- unsigned short (* MinorOpcode)( /* called for errors */
- ClientPtr /* client */);
- PrivateRec *devPrivates;
-} ExtensionEntry;
-
-/*
- * The arguments may be different for extension event swapping functions.
- * Deal with this by casting when initializing the event's EventSwapVector[]
- * entries.
- */
-typedef void (*EventSwapPtr) (xEvent *, xEvent *);
-
-extern _X_EXPORT EventSwapPtr EventSwapVector[128];
-
-extern _X_EXPORT void NotImplemented ( /* FIXME: this may move to another file... */
- xEvent *,
- xEvent *) _X_NORETURN;
-
-#define SetGCVector(pGC, VectorElement, NewRoutineAddress, Atom) \
- pGC->VectorElement = NewRoutineAddress;
-
-#define GetGCValue(pGC, GCElement) (pGC->GCElement)
-
-extern _X_EXPORT ExtensionEntry *AddExtension(
- char* /*name*/,
- int /*NumEvents*/,
- int /*NumErrors*/,
- int (* /*MainProc*/)(ClientPtr /*client*/),
- int (* /*SwappedMainProc*/)(ClientPtr /*client*/),
- void (* /*CloseDownProc*/)(ExtensionEntry * /*extension*/),
- unsigned short (* /*MinorOpcodeProc*/)(ClientPtr /*client*/)
-);
-
-extern _X_EXPORT Bool AddExtensionAlias(
- char* /*alias*/,
- ExtensionEntry * /*extension*/);
-
-extern _X_EXPORT ExtensionEntry *CheckExtension(const char *extname);
-extern _X_EXPORT ExtensionEntry *GetExtensionEntry(int major);
-
-#endif /* EXTENSIONSTRUCT_H */
-
+/***********************************************************
+
+Copyright 1987, 1998 The Open Group
+
+Permission to use, copy, modify, distribute, and sell this software and its
+documentation for any purpose is hereby granted without fee, provided that
+the above copyright notice appear in all copies and that both that
+copyright notice and this permission notice appear in supporting
+documentation.
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
+AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+Except as contained in this notice, the name of The Open Group shall not be
+used in advertising or otherwise to promote the sale, use or other dealings
+in this Software without prior written authorization from The Open Group.
+
+
+Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
+
+ All Rights Reserved
+
+Permission to use, copy, modify, and distribute this software and its
+documentation for any purpose and without fee is hereby granted,
+provided that the above copyright notice appear in all copies and that
+both that copyright notice and this permission notice appear in
+supporting documentation, and that the name of Digital not be
+used in advertising or publicity pertaining to distribution of the
+software without specific, written prior permission.
+
+DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
+ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
+DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
+ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
+ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
+SOFTWARE.
+
+******************************************************************/
+
+#ifndef EXTENSIONSTRUCT_H
+#define EXTENSIONSTRUCT_H
+
+#include "dix.h"
+#include "misc.h"
+#include "screenint.h"
+#include "extension.h"
+#include "gc.h"
+#include "privates.h"
+
+typedef struct _ExtensionEntry {
+ int index;
+ void (* CloseDown)( /* called at server shutdown */
+ struct _ExtensionEntry * /* extension */);
+ char *name; /* extension name */
+ int base; /* base request number */
+ int eventBase;
+ int eventLast;
+ int errorBase;
+ int errorLast;
+ int num_aliases;
+ char **aliases;
+ pointer extPrivate;
+ unsigned short (* MinorOpcode)( /* called for errors */
+ ClientPtr /* client */);
+ PrivateRec *devPrivates;
+} ExtensionEntry;
+
+/*
+ * The arguments may be different for extension event swapping functions.
+ * Deal with this by casting when initializing the event's EventSwapVector[]
+ * entries.
+ */
+typedef void (*EventSwapPtr) (xEvent *, xEvent *);
+
+extern _X_EXPORT EventSwapPtr EventSwapVector[128];
+
+extern _X_EXPORT void NotImplemented ( /* FIXME: this may move to another file... */
+ xEvent *,
+ xEvent *) _X_NORETURN;
+
+#define SetGCVector(pGC, VectorElement, NewRoutineAddress, Atom) \
+ pGC->VectorElement = NewRoutineAddress;
+
+#define GetGCValue(pGC, GCElement) (pGC->GCElement)
+
+extern _X_EXPORT ExtensionEntry *AddExtension(
+ const char* /*name*/,
+ int /*NumEvents*/,
+ int /*NumErrors*/,
+ int (* /*MainProc*/)(ClientPtr /*client*/),
+ int (* /*SwappedMainProc*/)(ClientPtr /*client*/),
+ void (* /*CloseDownProc*/)(ExtensionEntry * /*extension*/),
+ unsigned short (* /*MinorOpcodeProc*/)(ClientPtr /*client*/)
+);
+
+extern _X_EXPORT Bool AddExtensionAlias(
+ const char* /*alias*/,
+ ExtensionEntry * /*extension*/);
+
+extern _X_EXPORT ExtensionEntry *CheckExtension(const char *extname);
+extern _X_EXPORT ExtensionEntry *GetExtensionEntry(int major);
+
+#endif /* EXTENSIONSTRUCT_H */
+
diff --git a/xorg-server/include/input.h b/xorg-server/include/input.h
index 9ef726f4e..87bb2aa01 100644
--- a/xorg-server/include/input.h
+++ b/xorg-server/include/input.h
@@ -505,7 +505,7 @@ extern _X_EXPORT DeviceIntPtr GetPairedDevice(DeviceIntPtr kbd);
extern DeviceIntPtr GetMaster(DeviceIntPtr dev, int type);
extern _X_EXPORT int AllocDevicePair(ClientPtr client,
- char* name,
+ const char* name,
DeviceIntPtr* ptr,
DeviceIntPtr* keybd,
DeviceProc ptr_proc,
@@ -521,7 +521,7 @@ extern _X_EXPORT int generate_modkeymap(ClientPtr client, DeviceIntPtr dev,
extern int change_modmap(ClientPtr client, DeviceIntPtr dev, KeyCode *map,
int max_keys_per_mod);
extern int AllocXTestDevice(ClientPtr client,
- char* name,
+ const char* name,
DeviceIntPtr* ptr,
DeviceIntPtr* keybd,
DeviceIntPtr master_ptr,
diff --git a/xorg-server/include/misc.h b/xorg-server/include/misc.h
index 04e084b65..81da46b9d 100644
--- a/xorg-server/include/misc.h
+++ b/xorg-server/include/misc.h
@@ -279,7 +279,7 @@ static inline void wrong_size(void)
}
#endif
-#if !(defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C < 0x590)))
+#if !(defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)))
static inline int __builtin_constant_p(int x)
{
return 0;
diff --git a/xorg-server/include/os.h b/xorg-server/include/os.h
index cddf30ca8..78ece7101 100644
--- a/xorg-server/include/os.h
+++ b/xorg-server/include/os.h
@@ -309,10 +309,10 @@ extern _X_EXPORT void OsReleaseSignals (void);
extern _X_EXPORT void OsAbort (void) _X_NORETURN;
#if !defined(WIN32)
-extern _X_EXPORT int System(char *);
-extern _X_EXPORT pointer Popen(char *, char *);
+extern _X_EXPORT int System(const char *);
+extern _X_EXPORT pointer Popen(const char *, const char *);
extern _X_EXPORT int Pclose(pointer);
-extern _X_EXPORT pointer Fopen(char *, char *);
+extern _X_EXPORT pointer Fopen(const char *, const char *);
extern _X_EXPORT int Fclose(pointer);
#else
#define System(a) system(a)
@@ -494,6 +494,10 @@ extern _X_EXPORT size_t strlcpy(char *dst, const char *src, size_t siz);
extern _X_EXPORT size_t strlcat(char *dst, const char *src, size_t siz);
#endif
+#ifndef HAVE_STRNDUP
+extern _X_EXPORT char * strndup(const char *str, size_t n);
+#endif
+
/* Logging. */
typedef enum _LogParameter {
XLOG_FLUSH,
diff --git a/xorg-server/include/xkbfile.h b/xorg-server/include/xkbfile.h
index a4b99ee07..db7dbfa40 100644
--- a/xorg-server/include/xkbfile.h
+++ b/xorg-server/include/xkbfile.h
@@ -136,7 +136,7 @@ extern _X_EXPORT char * XkbConfigText(
unsigned /* format */
);
-extern _X_EXPORT char * XkbSIMatchText(
+extern _X_EXPORT const char * XkbSIMatchText(
unsigned /* type */,
unsigned /* format */
);
@@ -161,7 +161,7 @@ extern _X_EXPORT char * XkbDoodadTypeText(
unsigned /* format */
);
-extern _X_EXPORT char * XkbActionTypeText(
+extern _X_EXPORT const char * XkbActionTypeText(
unsigned /* type */,
unsigned /* format */
);