[WATCHDOG] Documentation/watchdog/watchdog-api.txt - fix watchdog daemon
Fix the simple watchdog daemon program in Doc/watchdog/watchdog-api.txt to build cleanly. Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be> Signed-off-by: Andrew Morton <akpm@osdl.org>
This commit is contained in:
parent
7071e522a5
commit
92930d9e81
@ -36,6 +36,9 @@ timeout or margin. The simplest way to ping the watchdog is to write
|
||||
some data to the device. So a very simple watchdog daemon would look
|
||||
like this:
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
int main(int argc, const char *argv[]) {
|
||||
int fd=open("/dev/watchdog",O_WRONLY);
|
||||
if (fd==-1) {
|
||||
|
Loading…
Reference in New Issue
Block a user