aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2024-06-30 12:37:04 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2024-06-30 12:37:04 +0200
commit314ec41b8e26ba6d161f0a47d08ce5f239d9bb1c (patch)
tree4ca541c9c14b9b015e5f12227e784a7a418d8d9a /nx-X11/programs/Xserver/hw/nxagent/NXproperty.c
parente18eb77f397b72c1a10141d2bafa2dc975ab7d38 (diff)
parent8f3b446b1336d2c54690468c062c3098df96ba96 (diff)
downloadnx-libs-314ec41b8e26ba6d161f0a47d08ce5f239d9bb1c.tar.gz
nx-libs-314ec41b8e26ba6d161f0a47d08ce5f239d9bb1c.tar.bz2
nx-libs-314ec41b8e26ba6d161f0a47d08ce5f239d9bb1c.zip
Merge branch 'uli42-pr/various10' into 3.6.x
Attribute GH PR #1075: https://github.com/ArcticaProject/nx-libs/pull/1075
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/NXproperty.c')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/NXproperty.c55
1 files changed, 30 insertions, 25 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c
index 4e61f26f0..7706bc7bc 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c
@@ -169,19 +169,20 @@ ProcChangeProperty(ClientPtr client)
#ifdef NXAGENT_ARTSD
{
- /* Do not process MCOPGLOBALS property changes,
- they are already set reflecting the server side settings.
- Just return success.
- */
- if (stuff->property == mcop_local_atom)
- return client->noClientException;
+ /*
+ * Do not process MCOPGLOBALS property changes,
+ * they are already set reflecting the server side settings.
+ * Just return success.
+ */
+ if (stuff->property == mcop_local_atom)
+ return client->noClientException;
}
#endif
#ifdef NXAGENT_SERVER
/* prevent clients from changing the NX_AGENT_VERSION property */
if (stuff->property == MakeAtom("NX_AGENT_VERSION", strlen("NX_AGENT_VERSION"), True))
- return client->noClientException;
+ return client->noClientException;
#endif
err = ChangeWindowProperty(pWin, stuff->property, stuff->type, (int)format,
@@ -189,23 +190,27 @@ ProcChangeProperty(ClientPtr client)
if (err != Success)
return err;
else
+#ifdef NXAGENT_SERVER
{
- if (nxagentOption(Rootless))
- {
- nxagentExportProperty(pWin, stuff->property, stuff->type, (int) format,
- (int) mode, len, (void *) &stuff[1]);
- }
+ if (nxagentOption(Rootless))
+ {
+ nxagentExportProperty(pWin, stuff->property, stuff->type, (int) format,
+ (int) mode, len, (void *) &stuff[1]);
+ }
- nxagentGuessClientHint(client, stuff->property, (char *) &stuff[1]);
+ nxagentGuessClientHint(client, stuff->property, (char *) &stuff[1]);
- nxagentGuessShadowHint(client, stuff->property);
+ nxagentGuessShadowHint(client, stuff->property);
- #ifdef NX_DEBUG_INPUT
- nxagentGuessDumpInputInfo(client, stuff->property, (char *) &stuff[1]);
- #endif
+ #ifdef NX_DEBUG_INPUT
+ nxagentGuessDumpInputInfo(client, stuff->property, (char *) &stuff[1]);
+ #endif
- return client->noClientException;
+ return client->noClientException;
}
+#else
+ return client->noClientException;
+#endif
}
/*****************
@@ -265,7 +270,7 @@ ProcGetProperty(ClientPtr client)
reply.type = X_Reply;
reply.sequenceNumber = client->sequence;
- #ifdef NXAGENT_SERVER
+#ifdef NXAGENT_SERVER
/*
* Creating a reply for WM_STATE property if it doesn't exist.
@@ -319,7 +324,7 @@ ProcGetProperty(ClientPtr client)
return(client->noClientException);
}
- #endif
+#endif /* NXAGENT_SERVER */
if (!pProp)
return NullPropertyReply(client, None, 0, &reply);
@@ -358,14 +363,14 @@ ProcGetProperty(ClientPtr client)
return(Success);
}
-/*
- * Return type, format, value to client
- */
+ /*
+ * Return type, format, value to client
+ */
n = (pProp->format/8) * pProp->size; /* size (bytes) of prop */
ind = stuff->longOffset << 2;
- /* If longOffset is invalid such that it causes "len" to
- be negative, it's a value error. */
+ /* If longOffset is invalid such that it causes "len" to
+ be negative, it's a value error. */
if (n < ind)
{