diff options
author | Lennart Poettering <lennart@poettering.net> | 2023-10-19 17:09:41 +0200 |
---|---|---|
committer | Luca Boccassi <luca.boccassi@gmail.com> | 2023-10-19 19:59:51 +0200 |
commit | 9bb64f1b8d2252d558f209a04b171d65b5ef131b (patch) | |
tree | 1065bca3b9298e595ddb6ae75107f414549bd106 /src | |
parent | Merge pull request #29629 from bluca/mount_tunnel_pidref (diff) | |
download | systemd-9bb64f1b8d2252d558f209a04b171d65b5ef131b.tar.xz systemd-9bb64f1b8d2252d558f209a04b171d65b5ef131b.zip |
pidref: make PIDREF_NULL const
That way compiler can put it in an immutable section
Diffstat (limited to 'src')
-rw-r--r-- | src/basic/pidref.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/basic/pidref.h b/src/basic/pidref.h index 0fdc02a54b..98ee0fef5c 100644 --- a/src/basic/pidref.h +++ b/src/basic/pidref.h @@ -9,7 +9,7 @@ typedef struct PidRef { int fd; /* only valid if pidfd are available in the kernel, and we manage to get an fd */ } PidRef; -#define PIDREF_NULL (PidRef) { .fd = -EBADF } +#define PIDREF_NULL (const PidRef) { .fd = -EBADF } /* Turns a pid_t into a PidRef structure on-the-fly *without* acquiring a pidfd for it. (As opposed to * pidref_set_pid() which does so *with* acquiring one, see below) */ |