← Commit list

b70ccd950

Rob Landley
Rob Landley
2006-01-22
SUCCESS Duration: 12s

Subject

Close bug 644: loop incrementing twice, skipping ever other device.

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Debian 14.2.0-19) 14.2.0

—

Build Log

(log yok)

Commit Diff GitHub →

libbb/loop.c+1 -1
@@ -98,7 +98,7 @@ int set_loop(char **device, const char *file, int offset)
/* Find a loop device. */
try=*device ? : dev;
for(i=0;rc;i++) {
- sprintf(dev, LOOP_FORMAT, i++);
+ sprintf(dev, LOOP_FORMAT, i);
/* Ran out of block devices, return failure. */
if(stat(try, &statbuf) || !S_ISBLK(statbuf.st_mode)) {
rc=ENOENT;