aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/hw
diff options
context:
space:
mode:
Diffstat (limited to 'nx-X11/programs/Xserver/hw')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Render.c9
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c2
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c2
3 files changed, 7 insertions, 6 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c
index 41a1ec02e..c5fd06352 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Render.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c
@@ -1678,10 +1678,11 @@ FIXME: Is this useful or just a waste of bandwidth?
#ifdef TEST
- fprintf(stderr, "nxagentTrapezoids: Source is a [%s] of geometry [%d,%d].\n",
- (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "pixmap" : "window"),
- pSrc -> pDrawable -> width, pSrc -> pDrawable -> height);
-
+ if (pSrc->pDrawable) {
+ fprintf(stderr, "nxagentTrapezoids: Source is a [%s] of geometry [%d,%d].\n",
+ (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "pixmap" : "window"),
+ pSrc -> pDrawable -> width, pSrc -> pDrawable -> height);
+ }
if (pSrc ->pDrawable != pDst -> pDrawable)
{
fprintf(stderr, "nxagentTrapezoids: Destination is a [%s] of geometry [%d,%d].\n",
diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c
index f18c09fe4..3d9ee8c7f 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c
@@ -735,7 +735,7 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio
client->sequence++;
#ifdef DEBUG
- if (client->requestLogIndex == MAX_REQUEST_LOG)
+ if ((client->requestLogIndex >= MAX_REQUEST_LOG) || (client->requestLogIndex <= 0))
client->requestLogIndex = 0;
client->requestLog[client->requestLogIndex] = MAJOROP;
client->requestLogIndex++;
diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c
index 3234c9929..2b642692f 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c
@@ -2351,7 +2351,7 @@ dump_char_ascii(CharInfoPtr cip)
byte = 0;
for (l = 0; l <= (cip->metrics.rightSideBearing -
cip->metrics.leftSideBearing); l++) {
- if (maskTab[l & 7] & row[l >> 3])
+ if (maskTab[l & 7] & (((int *)row)[l >> 3]))
putchar('X');
else
putchar('.');