Was getting "undefined reference to symbol 'dlsym@@GLIBC_2.2.5'".
Signed-off-by: Daniel Borca <dborca@yahoo.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
There's no reason to call gethostbyname() on the value returned
by uname() when asked just for a short name of a host. This may
also be wrong, when uname is set to one value, but in /etc/hosts
(or elsewhere) the "canonical" name is different. This is often
the case for localhost entry in /etc/hosts:
127.0.0.1 localhost myname
With this content of /etc/hosts, and uname being set to myname,
busybox hostname -s will return localhost, while regular
hostname utility returns myname.
Fix this by not calling gethostbyname() for the simple
'hostname -s' use.
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
GNU wget: wget google.com // ok
bb before: wget google.com // wget: not an http or ftp url
function old new delta
parse_url 317 339 +22
Signed-off-by: Lauri Kasanen <curaga@operamail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This is needed for, eg, hurd, which is known to have no constraints.
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
function old new delta
expand_main 709 690 -19
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Used to set p->filter_datapoint[i].d_dispersion = MAXDISP
and clear reachable bits, but this proved to be too agressive:
after step (tested with suspinding laptop for ~30 secs),
this caused all previous data to be considered invalid,
making us needing to collect full ~8 datapoins per peer
after step in order to start trusting them.
In turn, this was making poll interval decrease even after
step was done. (Poll interval decreases already before step
in this scenario, because we see large offsets and end up with
no good peer to select).
function old new delta
reset_peer_stats 157 139 -18
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Currently, sed pre-opens all files, which may cause EMFILE errors
on systems with low ulimit -n. Change sed to open one file at a time.
function old new delta
get_next_line 177 235 +58
sed_main 682 652 -30
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/1 up/down: 58/-30) Total: 28 bytes
Based on the patch by Daniel Borca <dborca@yahoo.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Most init processes implement a handler for SIGPWR that gracefully
stops all child processes when shutting down a machine. Some other
technologies rely on this signal - e.g. Busybox powered LXC
containers.
This patch makes busybox init halt when receiving SIGPWR.
Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Testcase: tar xvzf EMPTY_FILE
function old new delta
open_transformer 102 106 +4
get_header_tar 1781 1785 +4
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This change adds a definition for DHCP option 209. RFC 5071 defines code
209 as a configuration file for a PXE bootloader; this change uses
the string "pxeconffile" as its text identifier.
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
These places use ${var/search/replace}, $((n++) and
`type -p' constructs which are not-so-standard.
Replace with equivalent constructs.
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>