commit ccee88cb02cb54f586d22c53e8bb8865817c3dc4
parent 6e4136753bd0faa15c198118b05c529d96d908c5
Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date: Sun, 7 May 2023 12:56:46 +0200
sfeed: datetounix: code-style, change , to separate lines (-Wcomma)
Diffstat:
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/sfeed.c b/sfeed.c
@@ -470,12 +470,16 @@ datetounix(long long year, int mon, int day, int hour, int min, int sec)
if (!rem) {
is_leap = 1;
} else {
- if (rem >= 300)
- centuries = 3, rem -= 300;
- else if (rem >= 200)
- centuries = 2, rem -= 200;
- else if (rem >= 100)
- centuries = 1, rem -= 100;
+ if (rem >= 300) {
+ centuries = 3;
+ rem -= 300;
+ } else if (rem >= 200) {
+ centuries = 2;
+ rem -= 200;
+ } else if (rem >= 100) {
+ centuries = 1;
+ rem -= 100;
+ }
if (rem) {
leaps = rem / 4U;
rem %= 4U;