]>
Commit | Line | Data |
---|---|---|
cd1a2927 MT |
1 | /* SmoothWall helper program - smoothierebirth\r |
2 | *\r | |
3 | * This program is distributed under the terms of the GNU General Public\r | |
4 | * Licence. See the file COPYING for details.\r | |
5 | *\r | |
6 | * (c) Lawrence Manning, 2001\r | |
7 | * Simple program intended to be installed setuid(0) that can be used for\r | |
8 | * starting reboot.\r | |
9 | * \r | |
10 | * $Id: ipcoprebirth.c,v 1.2 2003/12/11 10:57:34 riddles Exp $\r | |
11 | * \r | |
12 | */\r | |
13 | \r | |
14 | #include <stdlib.h>\r | |
15 | #include "setuid.h"\r | |
16 | \r | |
17 | int main(void)\r | |
18 | {\r | |
19 | if (!(initsetuid()))\r | |
20 | exit(1);\r | |
21 | \r | |
22 | safe_system("/sbin/shutdown -r now");\r | |
23 | \r | |
24 | return 0;\r | |
25 | }\r |