os: use NULL instead of NullClient

No need to have another name for NULL, we can use NULL directly.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult 2025-07-16 12:06:12 +02:00 committed by Enrico Weigelt
parent 236e8e4656
commit 240e471325
2 changed files with 8 additions and 8 deletions

View File

@ -107,7 +107,7 @@ DetermineClientPid(struct _Client * client)
LocalClientCredRec *lcc = NULL;
pid_t pid = -1;
if (client == NullClient)
if (client == NULL)
return pid;
if (client == serverClient)
@ -451,7 +451,7 @@ void
ReserveClientIds(struct _Client *client)
{
#ifdef CLIENTIDS
if (client == NullClient)
if (client == NULL)
return;
assert(!client->clientIds);
@ -483,7 +483,7 @@ void
ReleaseClientIds(struct _Client *client)
{
#ifdef CLIENTIDS
if (client == NullClient)
if (client == NULL)
return;
if (!client->clientIds)
@ -518,7 +518,7 @@ ReleaseClientIds(struct _Client *client)
pid_t
GetClientPid(struct _Client *client)
{
if (client == NullClient)
if (client == NULL)
return -1;
if (!client->clientIds)
@ -544,7 +544,7 @@ GetClientPid(struct _Client *client)
const char *
GetClientCmdName(struct _Client *client)
{
if (client == NullClient)
if (client == NULL)
return NULL;
if (!client->clientIds)
@ -570,7 +570,7 @@ GetClientCmdName(struct _Client *client)
const char *
GetClientCmdArgs(struct _Client *client)
{
if (client == NullClient)
if (client == NULL)
return NULL;
if (!client->clientIds)

View File

@ -626,7 +626,7 @@ AllocNewConnection(XtransConnInfo trans_conn, int fd, CARD32 conn_time)
OsCommPtr oc = calloc(1, sizeof(OsCommRec));
if (!oc)
return NullClient;
return NULL;
oc->trans_conn = trans_conn;
oc->fd = fd;
oc->input = (ConnectionInputPtr) NULL;
@ -636,7 +636,7 @@ AllocNewConnection(XtransConnInfo trans_conn, int fd, CARD32 conn_time)
oc->flags = 0;
if (!(client = NextAvailableClient((void *) oc))) {
free(oc);
return NullClient;
return NULL;
}
client->local = ComputeLocalClient(client);
ospoll_add(server_poll, fd,