aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/dmx/dmxlog.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-05-02 09:01:55 +0200
committermarha <marha@users.sourceforge.net>2012-05-02 09:01:55 +0200
commit3d353f31ac1671d1b39c09b1f8d82c8811d3edd6 (patch)
treece19dbcec75ce7e87547f6f9b3495888aaea0966 /xorg-server/hw/dmx/dmxlog.c
parentb2a0f04a2984b290c1224fc1b1883d08b01a6231 (diff)
parente67b35e7a899da5805fcce3d390cb10ebcaffe91 (diff)
downloadvcxsrv-3d353f31ac1671d1b39c09b1f8d82c8811d3edd6.tar.gz
vcxsrv-3d353f31ac1671d1b39c09b1f8d82c8811d3edd6.tar.bz2
vcxsrv-3d353f31ac1671d1b39c09b1f8d82c8811d3edd6.zip
Merge remote-tracking branch 'origin/released'
Conflicts: xorg-server/os/connection.c
Diffstat (limited to 'xorg-server/hw/dmx/dmxlog.c')
-rw-r--r--xorg-server/hw/dmx/dmxlog.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/xorg-server/hw/dmx/dmxlog.c b/xorg-server/hw/dmx/dmxlog.c
index 33aee590a..3249c4867 100644
--- a/xorg-server/hw/dmx/dmxlog.c
+++ b/xorg-server/hw/dmx/dmxlog.c
@@ -86,6 +86,8 @@ ErrorF(const char *format, ...)
/** Provide an VFatalError function when used stand-alone. */
static void
+VFatalError(const char *format, va_list args) _X_ATTRIBUTE_PRINTF(1, 0) _X_NORETURN;
+static void
VFatalError(const char *format, va_list args)
{
vfprintf(stderr, format, args); /* RATS: We assume the format string
@@ -104,7 +106,9 @@ VErrorF(const char *format, va_list args)
}
#else
/** This function was removed between XFree86 4.3.0 and XFree86 4.4.0. */
-extern void AbortServer(void);
+extern void AbortServer(void) _X_NORETURN;
+static void
+VFatalError(const char *format, va_list args) _X_ATTRIBUTE_PRINTF(1, 0) _X_NORETURN;
static void
VFatalError(const char *format, va_list args)
{
@@ -163,6 +167,8 @@ dmxHeader(dmxLogLevel logLevel, DMXInputInfo * dmxInput,
/* Prints the error message with the appropriate low-level X output
* routine. */
static void
+dmxMessage(dmxLogLevel logLevel, const char *format, va_list args) _X_ATTRIBUTE_PRINTF(2, 0);
+static void
dmxMessage(dmxLogLevel logLevel, const char *format, va_list args)
{
if (logLevel == dmxFatal || logLevel >= dmxCurrentLogLevel) {
@@ -300,10 +306,11 @@ dmxLogVisual(DMXScreenInfo * dmxScreen, XVisualInfo * vi, int defaultVisual)
class = "DirectColor";
break;
}
+#define VisualLogFormat "0x%02lx %s %2db %db/rgb %3d 0x%04lx 0x%04lx 0x%04lx%s\n"
if (dmxScreen) {
dmxLogOutput(dmxScreen,
- "0x%02x %s %2db %db/rgb %3d 0x%04x 0x%04x 0x%04x%s\n",
+ VisualLogFormat,
vi->visualid, class, vi->depth, vi->bits_per_rgb,
vi->colormap_size,
vi->red_mask, vi->green_mask, vi->blue_mask,
@@ -311,7 +318,7 @@ dmxLogVisual(DMXScreenInfo * dmxScreen, XVisualInfo * vi, int defaultVisual)
}
else {
dmxLog(dmxInfo,
- " 0x%02x %s %2db %db/rgb %3d 0x%04x 0x%04x 0x%04x%s\n",
+ " " VisualLogFormat,
vi->visualid, class, vi->depth, vi->bits_per_rgb,
vi->colormap_size,
vi->red_mask, vi->green_mask, vi->blue_mask,