]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blame - src/misc-progs/ipfiredeath.c
Merge branch 'ppp-update' into beyond-next
[people/teissler/ipfire-2.x.git] / src / misc-progs / ipfiredeath.c
CommitLineData
12938118
MT
1/* SmoothWall helper program - smoothiedeath
2 *
3 * This program is distributed under the terms of the GNU General Public
4 * Licence. See the file COPYING for details.
5 *
6 * (c) Lawrence Manning, 2001
7 * Simple program intended to be installed setuid(0) that can be used for
8 * starting shutdown.
9 *
10 * $Id: ipcopdeath.c,v 1.2 2003/12/11 10:57:34 riddles Exp $
11 *
12 */
13
14#include <stdlib.h>
15#include "setuid.h"
16
17int main(void)
18{
19 if (!(initsetuid()))
20 exit(1);
21
22 safe_system("/sbin/shutdown -h now");
23
24 return 0;
25}