summaryrefslogtreecommitdiff
path: root/libbb (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Christian Grigis, christian.grigis at smartdata dot ch writes:Eric Andersen2004-04-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hello everyone, Busybox's insmod fails to locate a module when that module is the only one existing in the /lib/modules directory (with a unique name). Example: # find /lib/modules/ -type f /lib/modules/kernel/drivers/char/bios.o # insmod bios insmod: bios.o: no module by that name found # touch /lib/modules/dummy # find /lib/modules/ -type f /lib/modules/kernel/drivers/char/bios.o /lib/modules/dummy # insmod bios Using /lib/modules/kernel/drivers/char/bios.o As long as there is another file in the /lib/modules directory, insmod finds it OK. I tracked the problem down to 'check_module_name_match()' in insmod.c: It returns TRUE when a match is found, and FALSE otherwise. In the case where there is only one module in the /lib/modules directory (or more that one module, but all with the same name), 'recursive_action()' will return TRUE and we end up on line 4196 in 'insmod.c' which returns an error. [The reason it works with more than one module with different names is that in this case there will always be one not matching, 'recursive_action()' will return FALSE and we end up in line 4189.] Now, from the implementation of 'recursive_action()' and from other usages of it (tar.c, etc.), it seems to me that FALSE should be returned to indicate that we want to stop the recursion, so TRUE and FALSE should be inverted in 'check_module_name_match()'. At the same time, 'recursive_action()' continues to recurse even after the recursive call has returned FALSE; again in my understanding and other usages of it, we can safely stop recursing at this point. Here is my patch against 1.00-pre8:
* Add missing include filesEric Andersen2004-03-272-0/+2
|
* s/fileno\(stdin\)/STDIN_FILENO/gEric Andersen2004-03-272-2/+2
| | | | s/fileno\(stdout\)/STDOUT_FILENO/g
* Brian Pomerantz writes:Eric Andersen2004-03-231-1/+1
| | | | | | | | | | | | | | | | I've noticed a bug in the "autowidth" feature more, and is probably in others. The call to the function get_terminal_width_height() passes in a file descriptor but that file descriptor is never used, instead the ioctl() is called with 0. In more_main() the call to get_terminal_width_height() passes 0 as the file descriptor instead of fileno(cin). This isn't a problem when you more a file (e.g. "more /etc/passwd") but when you pipe a file to it (e.g. "cat /etc/passwd | more") the size of the terminal cannot be determined because file descriptor 0 is not a terminal. The fix is simple, I've attached a patch for more.c and get_terminal_width_height.c. BAPper
* Remove trailing whitespace. Update copyright to include 2004.Eric Andersen2004-03-1570-135/+135
|
* In spite of the feature freeze, check in a complete rework of route whichManuel Novoa III2004-03-101-2/+2
| | | | | | | | fixes some bugs, adds some error checking, and removes _lots_ of bloat. Text size on i386... old new ipv6 5425 3523 no ipv6 3143 2193
* My bug. :-(Manuel Novoa III2004-03-081-0/+1
|
* Fix/eliminate use of atolEric Andersen2004-03-062-3/+102
|
* Don't build these support functions for uClibc, as it always suppliesManuel Novoa III2004-03-061-0/+4
| | | | versions.
* Patch from Vernon Sauder.Glenn L McGrath2004-03-051-1/+1
| | | | | | The off_t type is not a consistent size; it depends on the kernel options (something about large file support). Therefore, the format string for printing an address is not always the same.
* bb_full_fd_action was incorrectly returning an error message causingGlenn L McGrath2004-02-231-2/+2
| | | | major breaking.
* For the time being, revert the changes for detecting copyingEric Andersen2004-02-221-6/+0
| | | | | | a directory into itself. It is harder to do this correctly than it appears. Not trying at all seems a better compromise for the time being, untill we can implement this correctly.
* Sometimes i get carried away with the use of function pointers, im sureGlenn L McGrath2004-02-211-5/+5
| | | | it seemed like a good idea at the time.
* Chris Larson (kergoth) writes:Eric Andersen2004-02-191-16/+6
| | | | | | | | | | | As Manuel points out, this is a flawed fix, and doesnt fix the following: mkdir -p cpa cpb cpc cp -a cpa cpa/cpb/cpc Attached what appears to be a more sane fix. Apply on top of previous. Please confirm sanity.
* Chris Larson (kergoth) writes:Eric Andersen2004-02-191-0/+16
| | | | | | | | | | | | | I was adding -s/--symbolic-link support to busybox cp when I noticed a bug with -r/-a. Test case: mkdir -p test/out cd test busybox cp -a * out/ Will never return until we run out of open files or similar. Coreutils cp on the other hand will error with "cannot copy a directory, `out', into itself, `out'". Patch attached.
* Accomodate the fact that newer libc versions may in fact notEric Andersen2004-02-131-6/+29
| | | | contain query_module and friends and more
* Make the loop support stuff be much less evil, and make it copeEric Andersen2004-02-064-81/+34
| | | | | | | | | with 2.6.x asm/posix_types.h, which has done singularly evil thing by yanking __kernel_dev_t and renaming it. The loop interface was really poorly designed in the first place. The new 64 bit loop interface looks to be somewhat less horrible, too bad it is only present in 2.6.x kernels. -Erik
* Vladimir N. Oleynik writes:Eric Andersen2004-02-051-3/+1
| | | | | | | | Ok. I found my mistake :( The trivial patch attached. --w vodz
* The variable 'complementaly' used to be allocated with calloc, which zeroed itEric Andersen2004-02-041-0/+2
| | | | | | | | | out during the allocation process. When vodz changed it to be allocated on the stack, he forgot to explicitly zero it, leaving its value filled with whatever used to be sitting on the stack. It would garbage values, depending on the garbage that happened to be sitting on the stack when the function was called. The result was that applets using bb_getopt_ulflags() were showing unpredictable behavior (such as segfaults), which naturally broke many things.
* s/u_int/unsigned int/gEric Andersen2004-01-301-4/+4
| | | | s/u_short/unsigned short/g
* Use proper C99 types throughout. So not use silly typedefs.Eric Andersen2004-01-301-47/+44
|
* Support new uClibc stdio core.Manuel Novoa III2004-01-301-4/+8
|
* Apply a couple of optimizationsEric Andersen2004-01-291-3/+5
|
* Teach busybox ps to get the correct uid when displaying stuffEric Andersen2004-01-271-3/+5
|
* Vodz, last_patch_123, patch have new version getopt_ulflags.Glenn L McGrath2004-01-221-28/+20
| | | | | | - size reduced 34 bytes - don`t use dynamic memory allocation - small indent correction.
* Patch from Atsushi Nemoto, recent MIPS kernel headersGlenn L McGrath2004-01-211-0/+4
| | | | | does not provide PAGE_SHIFT for userland (because now mips-linux kernel supports PAGESIZE other than 4K).
* Modify bb_lookup_port to allow the protocol to be specified, allowingGlenn L McGrath2004-01-171-2/+2
| | | | /etc/services support for inetd, netcat and tftp.
* Fix a bug where mount could check the wrong device. st_rdev is the correctEric Andersen2004-01-131-2/+5
| | | | | | | device ID iff the named file is a character or block special device. Otherwise it is meaningless junk, in which case st_dev should be used. This was done incorrectly, which could cause mount to display bogus mount info. -Erik
* Patch from Matt Kraai to fix debian bug #227081Glenn L McGrath2004-01-111-1/+1
| | | | | | | | | | | | | | | | | | cp does not truncate existing destinations. That is, after running echo foo > foo echo fubar > fubar cp foo fubar the contents of fubar are foo r instead of foo
* fix broken formattingEric Andersen2003-12-231-3/+3
|
* don't mess up errnoEric Andersen2003-12-231-2/+9
|
* bother. It seems I can't read.Eric Andersen2003-12-201-4/+0
|
* doh!Eric Andersen2003-12-201-1/+1
|
* Try to accomodate systems that do not define PAGE_SHIFTEric Andersen2003-12-201-0/+4
|
* Use low level file descriptors to match bb_copyfd_eofGlenn L McGrath2003-12-201-20/+19
|
* Change interface to bb_lookup_host, dont try and set port inside thisGlenn L McGrath2003-12-201-18/+15
| | | | | | | | function as there is no gracefull way of handling failures. Rename bb_getport to bb_lookup_port, allow a default port to be specified so it always returns a correct value. Modify ftpgetput/rdate/wget to use the new interface. wget/rdate now use etc/services with a falback default value.
* Allow escaped 8 bit characters in bb_opt_complementalyGlenn L McGrath2003-12-191-1/+1
|
* Fix a bug preventing use of escaped characters that use the signed bitGlenn L McGrath2003-12-191-3/+2
|
* Get vfork_daemon_rexec working under uclinuxRuss Dill2003-12-151-6/+57
|
* When a size of 0 is passed to copyfd_size, dont do anything, it wasGlenn L McGrath2003-11-241-1/+4
| | | | reading untill eof which breaks tar
* Fix warningGlenn L McGrath2003-11-221-2/+6
|
* As we no longer use function pointers for read in common archiving codeGlenn L McGrath2003-11-213-27/+38
| | | | | | | archive_xread can be replaced with bb_full_read, and archive_copy_file with bb_copyfd* bb_copyfd is split into two functions bb_copyfd_size and bb_copyfd_eof, they share a common backend.
* Dont over-read fd, use function pointer for hash function.Glenn L McGrath2003-11-201-29/+43
|
* Superficial changesGlenn L McGrath2003-11-201-19/+17
|
* Merge common parts of sha1sum and md5sum, which is everything except theGlenn L McGrath2003-11-102-1/+849
| | | | | | algorithms. Move algorithms to hash_fd and make them available via a common function.
* Fix rdate and ftpget/ftpput so they compile with the new xconnect.Eric Andersen2003-11-031-2/+2
| | | | | I have checked rdate. Someone should also check ftpget/ftpput to be sure they still work.
* Rework wget, the xconnect interface, and its various clientsEric Andersen2003-10-312-50/+38
| | | | | | | | | | | | | | in order to fix the problems with round robin DNS reported by Andrew Flegg: http://busybox.net/lists/busybox/2003-October/009579.html This removes the ipv6 specific xconnect dns lookups. I do not see why that would need to be special cased for ipv6 as was done, but that will just have to be tested. So IPV6 people -- please test this change! -Erik
* Patch from Arthur Othieno to fix a compiler warningEric Andersen2003-10-221-0/+2
|
* make this a little bit less messyEric Andersen2003-10-221-13/+11
|
* Fix an ommision preventing building, patch by Tito.Glenn L McGrath2003-10-091-3/+3
|