aboutsummaryrefslogtreecommitdiff
path: root/toys
diff options
context:
space:
mode:
Diffstat (limited to 'toys')
-rw-r--r--toys/other/losetup.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/toys/other/losetup.c b/toys/other/losetup.c
index 7f91ba1f..27d25a18 100644
--- a/toys/other/losetup.c
+++ b/toys/other/losetup.c
@@ -103,16 +103,16 @@ static int loopback_setup(char *device, char *file)
}
// Associate file with this device?
} else if (file) {
- char *s = xabspath(file, 1);
+ char *f_path = xabspath(file, 1);
- if (!s) perror_exit("file"); // already opened, but if deleted since...
+ if (!f_path) perror_exit("file"); // already opened, but if deleted since...
if (ioctl(lfd, LOOP_SET_FD, ffd)) {
- free(s);
+ free(f_path);
if (racy && errno == EBUSY) return 1;
perror_exit("%s=%s", device, file);
}
- xstrncpy((char *)loop->lo_file_name, s, LO_NAME_SIZE);
- free(s);
+ xstrncpy((char *)loop->lo_file_name, f_path, LO_NAME_SIZE);
+ free(f_path);
loop->lo_offset = TT.o;
loop->lo_sizelimit = TT.S;
if (ioctl(lfd, LOOP_SET_STATUS64, loop)) perror_exit("%s=%s", device, file);