aboutsummaryrefslogtreecommitdiff
path: root/nx-X11
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2019-09-01 21:22:17 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2019-09-29 16:57:43 +0200
commit5aee32e9d8db69fa0ce372e7b2b08696224e48ec (patch)
tree62258e6434873ca1efa8b131e393fed2b2bb84c2 /nx-X11
parentc577775f9ff42b65d4f2cdb1d31cfa7073679065 (diff)
downloadnx-libs-5aee32e9d8db69fa0ce372e7b2b08696224e48ec.tar.gz
nx-libs-5aee32e9d8db69fa0ce372e7b2b08696224e48ec.tar.bz2
nx-libs-5aee32e9d8db69fa0ce372e7b2b08696224e48ec.zip
nxagent: drop nxagentRenderTrap
nxagentRenderTrap is rather old. This flag is set when internal pixmap creation returns a pixmap with depth 0. Following that the RENDER extension is effectively disabled. However: there's no code that could create a pixmap with depth 0, so let's simplify our code by removing nxagentRenderTrap altogether. Fixes ArcticaProject/nx-libs#841
Diffstat (limited to 'nx-X11')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/NXextension.c15
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/NXrender.c20
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Pixmap.c35
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Trap.c7
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Trap.h7
5 files changed, 0 insertions, 84 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c
index 9ec6be8ef..0b832cc7d 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c
@@ -95,13 +95,6 @@ ProcQueryExtension(ClientPtr client)
{
i = FindExtension((char *)&stuff[1], stuff->nbytes);
if (i < 0
-
- /*
- * Hide RENDER if our implementation
- * is faulty.
- */
-
- || (nxagentRenderTrap && strcmp(extensions[i]->name, "RENDER") == 0)
#ifdef XCSECURITY
/* don't show insecure extensions to untrusted clients */
|| (client->trustLevel == XSecurityClientUntrusted &&
@@ -149,14 +142,6 @@ ProcListExtensions(ClientPtr client)
!extensions[i]->secure)
continue;
#endif
- /*
- * Hide RENDER if our implementation
- * is faulty.
- */
-
- if (nxagentRenderTrap && strcmp(extensions[i]->name, "RENDER") == 0)
- continue;
-
total_length += strlen(extensions[i]->name) + 1;
reply.nExtensions += 1 + extensions[i]->num_aliases;
for (j = extensions[i]->num_aliases; --j >= 0;)
diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c
index 190f746a4..7456bd3a5 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c
@@ -1665,16 +1665,6 @@ ProcRenderDispatch (ClientPtr client)
REQUEST(xReq);
- /*
- * Let the client fail if we are
- * hiding the RENDER extension.
- */
-
- if (nxagentRenderTrap)
- {
- return BadRequest;
- }
-
if (stuff->data < RenderNumberRequests)
{
#ifdef TEST
@@ -1707,16 +1697,6 @@ SProcRenderDispatch (ClientPtr client)
REQUEST(xReq);
- /*
- * Let the client fail if we are
- * hiding the RENDER extension.
- */
-
- if (nxagentRenderTrap)
- {
- return BadRequest;
- }
-
if (stuff->data < RenderNumberRequests)
{
/*
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c
index 58fea6c05..7a0fcd535 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c
@@ -322,41 +322,6 @@ PixmapPtr nxagentCreatePixmap(ScreenPtr pScreen, int width, int height,
pVirtualPriv -> pVirtualPixmap = NULL;
pVirtualPriv -> pPicture = NULL;
- /*
- * Check that the virtual pixmap is created with
- * the appropriate bits-per-plane, otherwise free
- * everything and return.
- */
-
- if (pVirtual -> drawable.bitsPerPixel == 0)
- {
- #ifdef WARNING
-
- fprintf(stderr, "nxagentCreatePixmap: WARNING! Virtual pixmap at [%p] has invalid "
- "bits per pixel.\n", (void *) pVirtual);
-
- fprintf(stderr, "nxagentCreatePixmap: WARNING! Real pixmap created with width [%d] "
- "height [%d] depth [%d] bits per pixel [%d] and allocation hint [%d].\n",
- pPixmap -> drawable.width,
- pPixmap -> drawable.height = height, pPixmap -> drawable.depth,
- pPixmap -> drawable.bitsPerPixel,
- usage_hint);
- #endif
-
- if (!nxagentRenderTrap)
- {
- #ifdef WARNING
- fprintf(stderr, "Warning: Disabling render extension due to missing pixmap format.\n");
- #endif
-
- nxagentRenderTrap = 1;
- }
-
- nxagentDestroyPixmap(pPixmap);
-
- return NullPixmap;
- }
-
#ifdef TEST
fprintf(stderr, "nxagentCreatePixmap: Created pixmap at [%p] virtual at [%p] with width [%d] "
"height [%d] depth [%d] and allocation hint [%d].\n",
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.c b/nx-X11/programs/Xserver/hw/nxagent/Trap.c
index f219bb43c..4fe12bede 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Trap.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.c
@@ -42,13 +42,6 @@ int nxagentGCTrap = 0;
int nxagentScreenTrap = 0;
/*
- * Set if we detected that our RENDER
- * implementation is faulty.
- */
-
-int nxagentRenderTrap = 0;
-
-/*
* Set if we are executing a GC operation
* only on the X side. Used to avoid
* reentrancy in FB layer.
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.h b/nx-X11/programs/Xserver/hw/nxagent/Trap.h
index 9f0c055c8..3d4bd11f9 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Trap.h
+++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.h
@@ -43,13 +43,6 @@ extern int nxagentGCTrap;
extern int nxagentScreenTrap;
/*
- * Set if we detected that our RENDER
- * implementation is faulty.
- */
-
-extern int nxagentRenderTrap;
-
-/*
* Set if we are executing a GC operation
* only on the X side. Used to avoid
* reentrancy in FB layer.