We never use the field and this is not going to change...
This addresses a weird asymmetry, as create_session_message() always
went to the process' own PID when doing pidfds but otherwise (i.e.
without pidfds) would honour the PID specified as function parameter.
typedef struct SessionContext {
const uid_t uid;
- const pid_t pid;
const char *service;
const char *type;
const char *class;
r = sd_bus_message_append(m,
pidfd >= 0 ? "uhsssssussbss" : "uusssssussbss",
(uint32_t) context->uid,
- pidfd >= 0 ? pidfd : context->pid,
+ pidfd >= 0 ? pidfd : 0,
context->service,
context->type,
context->class,
const SessionContext context = {
.uid = ur->uid,
- .pid = 0,
.service = service,
.type = type,
.class = class,