summaryrefslogtreecommitdiff
path: root/util-linux/losetup.c
AgeCommit message (Collapse)Author
2007-04-19loop device code: readability improvementDenis Vlasenko
2007-02-03suppress warnings about easch <applet>_main() havingDenis Vlasenko
no preceding prototype
2006-10-08attempt to regularize atoi mess.Denis Vlasenko
2006-10-03getopt_ulflags -> getopt32.Denis Vlasenko
It is impossible to formulate sane ABI based on size of ulong because it can be 32-bit or 64-bit. Basically it means that you cannot portably use more that 32 option chars in one call anyway... Make it explicit.
2006-09-29losetup: use /dev/loopN or /dev/loop/N according to CONFIG_FEATURE_DEVFS=n/yDenis Vlasenko
2006-09-27losetup: with no arguments lists all /dev/loopN. Corrected help text.Denis Vlasenko
(patch by Vladimir Dronnikov <dronnikov@gmail.ru>)
2006-09-22losetup: getopt_ulflags'ification + small fix for perror_nomsgDenis Vlasenko
2006-07-02Standardize on the vi editing directives being on the first line."Robert P. J. Day"
2006-01-25just whitespaceTim Riker
2006-01-13- revert last change for now..Bernhard Reutner-Fischer
2006-01-13this applet needlessly big! TODO: bb_getopt_ulflags()Bernhard Reutner-Fischer
- use atol for the offset, which is always in bytes. Small step in eventually dropping bb_xparse_number().
2005-12-21When you went "losetup -d /dev/loop0 /dev/loop1" the error message was strange.Rob Landley
2005-11-29Fix losetup so that it A) actually works again, B) has much better errorRob Landley
messages, C) can show the current association (if any) when called with only one argument. Update the documentation a lot too. Remind me to add a test suite for this thing. I think I've figured out how to handle root-only testsuites...
2005-08-10Major rewrite of mount, umount, losetup. Untangled lots of code, shrunkRob Landley
things down a bit, fixed a number of funky corner cases, added support for several new features (things like mount --move, mount --bind, lazy unounts, automatic detection of loop mounts, and so on). Probably broke several other things, but it's fixable. (Bang on it, tell me what doesn't work for you...) Note: you no longer need to say "-o loop". It does that for you when necessary. Still need to add "user mount" support, which involves making mount suid. Not too hard to do under the new infrastructure, just haven't done it yet... The previous code had the following notes, that belong in the version control comments: - * 3/21/1999 Charles P. Wright <cpwright@cpwright.com> - * searches through fstab when -a is passed - * will try mounting stuff with all fses when passed -t auto - * - * 1999-04-17 Dave Cinege...Rewrote -t auto. Fixed ro mtab. - * - * 1999-10-07 Erik Andersen <andersen@codepoet.org>. - * Rewrite of a lot of code. Removed mtab usage (I plan on - * putting it back as a compile-time option some time), - * major adjustments to option parsing, and some serious - * dieting all around. - * - * 1999-11-06 mtab support is back - andersee - * - * 2000-01-12 Ben Collins <bcollins@debian.org>, Borrowed utils-linux's - * mount to add loop support. - * - * 2000-04-30 Dave Cinege <dcinege@psychosis.com> - * Rewrote fstab while loop and lower mount section. Can now do - * single mounts from fstab. Can override fstab options for single - * mount. Common mount_one call for single mounts and 'all'. Fixed - * mtab updating and stale entries. Removed 'remount' default. - *
2003-07-30Lars Ekman writes:Eric Andersen
When using "losetup" the device is always setup as Read-Only. (I have only tested with the -o flag, but looking at the code the problem seems general) The problem is the "opt" variable in "losetup.c" that is reused in the "set_loop()" call. Clear it before the call and everything is OK; opt = 0; /* <-------- added line */ if (delete) return del_loop (argv[optind]) ? EXIT_SUCCESS : EXIT_FAILURE; else return set_loop (argv[optind], argv[optind + 1], offset, &opt) ? EXIT_FAILURE : EXIT_SUCCESS; } Best Regards, Lars Ekman
2003-03-19Major coreutils update.Manuel Novoa III
2002-03-20* include/applets.h (CONFIG_LOSETUP): New.Matt Kraai
* include/usage.h (losetup_trivial_usage, losetup_full_usage): New. * util-linux/Makefile: Add losetup.o. * util-linux/config.in: Add losetup prompt. * util-linux/losetup.c: New.