randr: use X_SEND_REPLY_SIMPLE() for sending simple replies

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult
2025-08-29 17:07:33 +02:00
committed by Enrico Weigelt
parent 4aff0544ea
commit 331510cc8f
8 changed files with 31 additions and 112 deletions

View File

@@ -335,19 +335,10 @@ leaseReturned:
RRLeaseChangeState(lease, RRLeaseCreating, RRLeaseRunning);
xRRCreateLeaseReply rep = {
.type = X_Reply,
.nfd = 1,
.sequenceNumber = client->sequence,
};
if (client->swapped) {
swaps(&rep.sequenceNumber);
swapl(&rep.length);
}
WriteToClient(client, sizeof (rep), &rep);
return Success;
return X_SEND_REPLY_SIMPLE(client, rep);
bail_lease:
free(lease);