summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Fietkau2018-07-05 09:13:31 +0000
committerFelix Fietkau2018-07-05 09:13:31 +0000
commita0372ac0713957365120cf42c5469c635c1e0232 (patch)
treeef01935cc518be92ceb789e7a2b0f7a0da08e3c1
parentdfb68f8556df63878add145ad9c656381bc20656 (diff)
downloadprocd-a0372ac0713957365120cf42c5469c635c1e0232.tar.gz
procd: increase watchdog fd_buf storage size to fix gcc8 build error
Signed-off-by: Felix Fietkau <nbd@nbd.name>
-rw-r--r--watchdog.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/watchdog.c b/watchdog.c
index ec10ba6..7493a0f 100644
--- a/watchdog.c
+++ b/watchdog.c
@@ -142,10 +142,11 @@ int watchdog_frequency(int frequency)
char* watchdog_fd(void)
{
- static char fd_buf[3];
+ static char fd_buf[12];
if (wdt_fd < 0)
return NULL;
+
snprintf(fd_buf, sizeof(fd_buf), "%d", wdt_fd);
return fd_buf;