summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Spooren2023-10-26 07:28:11 +0000
committerDaniel Golle2024-03-20 18:47:29 +0000
commit428f40e7984f537096a7dbc418a100abaab04be5 (patch)
treebf300ec9a7a07aaa9aa5b159ab54fd7e73470051
parent79f8cfa58ee7ec828a0fe3519ce696be42a81b2d (diff)
test commit fixing warnings
Signed-off-by: Paul Spooren <mail@aparcar.org>
-rw-r--r--system.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/system.c b/system.c
index 8df606f..21ec3cd 100644
--- a/system.c
+++ b/system.c
@@ -51,9 +51,8 @@ static const char *system_rootfs_type(void) {
static char fstype[16] = { 0 };
char *mountstr = NULL, *mp = "/", *pos, *tmp;
FILE *mounts;
- ssize_t nread;
size_t len = 0;
- bool found;
+ bool found = false;
if (initramfs)
return "initramfs";
@@ -65,9 +64,7 @@ static const char *system_rootfs_type(void) {
if (!mounts)
return NULL;
- while ((nread = getline(&mountstr, &len, mounts)) != -1) {
- found = false;
-
+ while (getline(&mountstr, &len, mounts) != -1) {
pos = strchr(mountstr, ' ');
if (!pos)
continue;