Processes (run by the root user) whose first character of the zeroth command
line argument is `@` are excluded from the killing spree, much the same way as
kernel threads are excluded too. Thus, a daemon which wants to take advantage
-of this logic needs to place the following at the top of its main() function:
+of this logic needs to place the following at the top of its `main()` function:
```c
-…
-[0][0] = '@';
-…
+...
+argv[0][0] = '@';
+...
```
And that's already it. Note that this functionality is only to be used by
#include <unistd.h>
int main(int argc, char *argv[]) {
- …
+ ...
if (access("/etc/initrd-release", F_OK) >= 0)
argv[0][0] = '@';
- …
+ ...
}
```
program consult this blog story: [Socket
Activation](http://0pointer.de/blog/projects/socket-activation.html)
-* Consider having a look at the [initrd Interface of systemd](http://www.freedesktop.org/wiki/Software/systemd/InitrdInterface)
+* Consider having a look at the [initrd Interface of systemd](https://systemd.io/INITRD_INTERFACE/).