summaryrefslogtreecommitdiff
path: root/coreutils/ln.c
AgeCommit message (Collapse)Author
2009-11-28*: remove a few more cases of argc usage. -89 bytes.Denys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2007-10-11add -fvisibility=hidden to CC flags, mark XXX_main functionsDenis Vlasenko
EXTERNALLY_VISIBLE. 5% size reduction of libbusybox.so
2007-10-01'simple' error message functions by Loic Grenie <loic.grenie@gmail.com>.Denis Vlasenko
263 bytes saved.
2007-09-24*: kill bb_get_last_path_component, replace with two functionsDenis Vlasenko
(one which strips trailing slash and one which does not) wget: straighten out as a result of above change text data bss dec hex filename 5056 1 0 5057 13c1 busybox.t4/networking/wget.o 5022 0 0 5022 139e busybox.t5/networking/wget.o
2007-08-18don't pass argc in getopt32, it's superfluousDenis Vlasenko
(add/remove: 0/0 grow/shrink: 12/131 up/down: 91/-727) Total: -636 bytes text data bss dec hex filename 773469 1058 11092 785619 bfcd3 busybox_old 772644 1058 11092 784794 bf99a busybox_unstripped
2007-08-16whitespace fixes, no code changesDenis Vlasenko
2007-05-26usage.c: remove reference to busybox.hDenis Vlasenko
*: s/include "busybox.h"/include "libbb.h"
2007-04-10audit small applets and mark some of them as NOFORK.Denis Vlasenko
Put big scary warnings in relevant places.
2007-02-03suppress warnings about easch <applet>_main() havingDenis Vlasenko
no preceding prototype
2007-01-29preparatory patch for -Wwrite-strings #1Denis Vlasenko
2006-10-21cp: add support for -s, -l. Fix free(nonmalloc) bug.Denis Vlasenko
Add doc on POSIX's rules on -i and -f (insane!). ln: make "ln dangling_symlink new_link" work.
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-08-03Remove bb_ prefixes from xfuncs.c (and a few other places), consolidateRob Landley
things like xasprintf() into xfuncs.c, remove xprint_file_by_name() (it only had one user), clean up lots of #includes... General cleanup pass. What I've been doing for the last couple days. And it conflicts! I've removed httpd.c from this checkin due to somebody else touching that file. It builds for me. I have to catch a bus. (Now you know why I'm looking forward to Mercurial.)
2006-07-12Add one-line GPL boilerplate to numerous (but not all yet) source files."Robert P. J. Day"
2006-03-06Robert P. Day removed 8 gazillion occurrences of "extern" on functionRob Landley
definitions. (That should only be on prototypes.)
2005-12-12printf() arguments shouldn't be passed straight from user supplied data.Rob Landley
(Security thingy.)
2005-09-29change interface to bb_xasprintf() - more perfect for me."Vladimir N. Oleynik"
ln.c: error_msg(str)->error_msg(%s, str) - remove standart "feature" for hackers reduce 100 bytes don't care in sum
2005-04-29Patch from Matthew S. Wood:Rob Landley
> The following patch adds support for the -S and -b flags to `ln'. These > flags [especially -b] are used extensively in Debian pre and post > installation scripts. Comments from Vladimir Oleynik influenced the final patch, and I also ripped out the in-file changelog since it belongs here. At the time, it said: /* Apr 15, 2004 Matthew S. Wood (mwood@realmsys.com) * * Implement '-b' (backup) flag. * Implement '-S' (backup suffix) flag. * * * Mar 16, 2003 Manuel Novoa III (mjn3@codepoet.org) * * Fixed bug involving -n option. Essentially, -n was always in effect. */
2004-03-15Remove trailing whitespace. Update copyright to include 2004.Eric Andersen
2004-01-08Patch from Bastian Blank to fix debian bug #226722, test case: Glenn L McGrath
mkdir foo touch foo/bar ln -s bar foo/baz
2003-12-31Batch from Bastian Blank to fix debian bug #216435;Glenn L McGrath
When linking a non existing file busybox ln will report the target missind and not the source:
2003-07-14Update a bunch of docs. Run a script to update my email addr.Eric Andersen
2003-03-19Major coreutils update.Manuel Novoa III
2002-07-19Applied vodz' patches #49 and #50 (with a small correction in runshell.c)Robert Griebl
#49: I found one memory overflow and memory leak in "ln" applet. Last patch reduced also 54 bytes. ;) #50: I found bug in loginutils/Makefile.in. New patch have also new function to libbb and aplied this to applets and other cosmetic changes.
2002-04-06Apply lash_patch35 from vodz, which brings several nice size_optimizations.Eric Andersen
2001-10-24Major rework of the directory structure and the entire build system.Eric Andersen
-Erik
2001-04-25Move messages.c to libbb. Make each string in messages.c be its own .o file.Eric Andersen
This way, we can new get rid of all that tedious #define rubbish we used to need to enable specific messages. This way is enormously simpler, and as a bonus also ends up saving us 96 bytes. -Erik
2001-02-20It turns out that DODMALLOC was broken when I reorganized busybox.hEric Andersen
header file usage before the 0.49 release. To fix it, I had to move the '#include "busybox.h"' to the end of the list of #include files. -Erik
2001-02-15use perror_msg instead of perror to print the applet name.Eric Andersen
-Erik
2001-02-14This patch, put together by Manuel Novoa III, is a merge of workEric Andersen
done by Evin Robertson (bug#1105) and work from Manuel to make usage messages occupy less space and simplify how usage messages are displayed.
2001-01-27Fix up copyright msgs. Bump version to 0.49 in preparation for0_49Eric Andersen
a release. Update the website with release details. -Erik
2001-01-27Fix header file usage -- there were many unnecessary header files included inEric Andersen
busybox.h which slowed compiles. I left only what was needed and then fixed up all the apps to include their own header files. I also fixed naming for pwd.h and grp.h functions. Tested to compile and run with libc5, glibc, and uClibc. -Erik
2001-01-23#define -> static const int. Also got rid of some big static buffers.Mark Whitley
2000-12-07Changed names of functions in utility.c and all affected files, to makeMark Whitley
compliant with the style guide. Everybody rebuild your tags file!
2000-10-04Patch from Matt Kraai: "When it encounters a problem creating a link, lnEric Andersen
shouldn't give up entirely but instead continue processing the rest of its arguments. The attached patch does this."
2000-10-04Rewrite to use getopt and return instead of exit, a seperate function ↵Glenn L McGrath
(fs_link) does the actual work.
2000-09-25Renamed "internal.h" to the more sensible "busybox.h".Eric Andersen
-Erik
2000-09-13Fix calls to {m,c,re}alloc so that they use x{m,c,re}alloc instead ofMatt Kraai
segfaulting or handling errors the same way themselves.
2000-07-16Extract usage information into a separate file.Matt Kraai
2000-07-14Use errorMsg rather than fprintf.Matt Kraai
2000-07-11Re-enable ln -n in the help.Eric Andersen
-Erik
2000-07-11Another patch from Matt Kraai <kraai@alumni.carnegiemellon.edu>:Eric Andersen
> > The following patch allows ln -n to function like GNU. It also fixes a > typo with my previous patch to add support for ln FILE DIRECTORY. And > it removes some code that checks the maximum length of the filenames. I > can't figure out why that code is necessary. Anyone know? > > Matt
2000-07-10Remove yet more kernel header dependancies.Eric Andersen
-Erik
2000-07-10From Matt Kraai <kraai@alumni.carnegiemellon.edu>:Eric Andersen
Howdy, Bug #1006 reports that ln -s /tmp/foo . does not work correctly. In fact, it appears that any instantiation of ln -s FILE... DIRECTORY does not work. The following patch adds support for this form, which then fixes the particular instance noted in the bug report. In the process, I needed the basename function. This appears in the string.h provided by glibc, but not uC-libc. So I wrote my own to go in utility.c, called get_last_path_component. I also modified the basename utility to use this function. At some point it might be desirous to use the basename from the library if it exists, and otherwise compile our own. But I don't know how to do this. Matt
2000-06-22Pavel Roskin <proski@gnu.org> just found a nasty memoryEric Andersen
corruption bug. Disabling 'ln -n' till it is fixed. -Erik
2000-06-21Document 'ln --'Eric Andersen
-Erik
2000-06-19Updates to a number of apps to remove warnings/compile errors under libc5.Eric Andersen
Tested under both libc5 and libc6 and all seems well with these fixes. -Erik
2000-06-18Check for 3 and more arguments was incorrectPavel Roskin
It is only allowed for linking to a directory But linking to a directory still fails and may be removed
2000-06-15ln: fixed command line parser. Added support for "--"Pavel Roskin
2000-06-06Fixed a bunch of stuff:Eric Andersen
* Fixed segfault caused by "touch -c" * Fixed segfault caused by "rm -f" * Fixed segfault caused by "ln -s -s" and similar abuses. * Fixed segfault caused by "cp -a -a" and similar abuses. * Implemented "rm -- <foo>" updated docs accordingly. -Erik