From fc6c8c1e74b12c5a8482f153c2021f84671b3e8e Mon Sep 17 00:00:00 2001 From: gilex-dev Date: Mon, 13 Nov 2023 21:43:40 +0100 Subject: [PATCH] fix format warning --- src/main.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 1d92848..0914fd3 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -194,10 +194,10 @@ void handleTime() { server.arg(args[arg])[1]}; char buff_m[2][2] = {server.arg(args[arg])[3], server.arg(args[arg])[4]}; - sprintf(time_all[arg * 2][server.arg("rule").toInt()], "%s", - buff_h); - sprintf(time_all[arg * 2 + 1][server.arg("rule").toInt()], "%s", - buff_m); + sprintf(time_all[arg * 2][server.arg("rule").toInt()], "%s%s", + buff_h[0], buff_h[1]); + sprintf(time_all[arg * 2 + 1][server.arg("rule").toInt()], + "%s%s", buff_m[0], buff_m[1]); EEPROM.put(server.arg("rule").toInt() * 4 + arg * 64, atoi(time_all[arg * 2][server.arg("rule").toInt()]));