> 2018-07-25:
> ntpd: increase MIN_FREQHOLD by 3
> This means we'll start correcting frequency ~5 minutes after start,
> not ~3.5 ones.
> With previous settings I still often see largish ~0.7s initial offsets
> only about 1/2 corrected before frequency correction kicks in,
> resulting in ~200ppm "correction" which is then slowly undone.
Review of real-world results of the above shows that with small
initial offsets, freq correction can be allowed to kick in sooner,
whereas with large (~0.8s) offsets, we still start freq correction
a bit too soon.
Let's rebalance this a bit.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Add support for querying and parsing SRV DNS records.
function old new delta
send_queries 1711 1865 +154
qtypes 72 80 +8
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Under some circumstances, a DNS reply might contain no resource records,
e.g. when a valid domain is queried that does not have records of the
requested type.
Example with nslookup from BIND dnsutils:
$ nslookup -q=SRV example.org
Server: 10.11.12.13
Address: 10.11.12.13#53
Non-authoritative answer:
*** Can't find example.org: No answer
Currently the busybox nslookup applet simply prints nothing after the
"Non-authoritative answer:" line in the same situation.
This change modifies nslookup to either print "Parse error" or "No answer"
diagnostics, depending on the parse_reply() return value.
function old new delta
send_queries 1676 1711 +35
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
huft_build() has way too many params
function old new delta
inflate_block 1293 1281 -12
huft_build 1085 1058 -27
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 0/2 up/down: 0/-39) Total: -39 bytes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
> I'm trying to connect to a Korenix 3005 switch through telnet
> for management purposes, and all is well except for the backspace character
> - seems like my switch doesn't handle it too well and instead of erasing
> the last character all it does is print some garbage to the screen.
> I've had the same issue before while using putty, but saw a solution that
> suggests to enable "Telnet special commands" in the options menu, and it
> worked.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
When crond is built with FEATURE_CROND_SPECIAL_TIMES enabled, it creates
a file called 'crond.reboot' at CONFIG_PID_FILE_PATH, but if
FEATURE_PIDFILE is disabled, this will be an empty string and the file
will be created in the root directory, which is undesirable.
This commit makes PID_FILE_PATH depend on FEATURE_CROND_SPECIAL_TIMES as
well as FEATURE_PIDFILE so that you get sensible behaviour in crond when
FEATURE_PIDFILE is switched off.
Signed-off-by: James Byrne <james.byrne@origamienergy.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
If sub is empty, avoids an infinite loop.
function old new delta
count_strstr 45 63 +18
Signed-off-by: Martin Lewis <martin.lewis.x84@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Changed safe_read to be symmetrical to safe_write, it shall
never return EINTR because it calls read multiple times,
the error is considered transient.
function old new delta
safe_read 44 57 +13
Signed-off-by: Martin Lewis <martin.lewis.x84@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Some 32-bit architectures no longer have the 32-bit time_t syscalls.
Instead they have suffixed syscalls that returns a 64-bit time_t. If
the architecture doesn't have the non-suffixed syscall and is using a
64-bit time_t let's use the suffixed syscall instead.
This fixes build issues when building for RISC-V 32-bit with 5.1+ kernel
headers.
If an architecture only supports the suffixed syscalls, but is still
using a 32-bit time_t report a compilation error. This avoids us have to
deal with converting between 64-bit and 32-bit values. There are
currently no architectures where this is the case.
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Some 32-bit architectures no longer have the 32-bit time_t syscalls.
Instead they have suffixed syscalls that returns a 64-bit time_t. If
the architecture doesn't have the non-suffixed syscall and is using a
64-bit time_t let's use the suffixed syscall instead.
This fixes build issues when building for RISC-V 32-bit with 5.1+ kernel
headers.
If an architecture only supports the suffixed syscalls, but is still
using a 32-bit time_t report a compilation error. This avoids us have to
deal with converting between 64-bit and 32-bit values. There are
currently no architectures where this is the case.
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Some 32-bit architectures no longer have the 32-bit time_t syscalls.
Instead they have suffixed syscalls that returns a 64-bit time_t. If
the architecture doesn't have the non-suffixed syscall and is using a
64-bit time_t let's use the suffixed syscall instead.
This fixes build issues when building for RISC-V 32-bit with 5.1+ kernel
headers.
If an architecture only supports the suffixed syscalls, but is still
using a 32-bit time_t fall back to the libc call.
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
The following caused udhcpc to segfault:
busybox udhcpc -i lo -s /dev/null -x 0x3d:
function old new delta
udhcp_str2optset 629 641 +12
Signed-off-by: Michal Kazior <michal@plume.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
The output of the command "route -n -A inet6" may be corrupted
due to partially initialized structure snaddr6 in the function
INET6_displayroutes.
Signed-off-by: Tomas Paukrt <tomaspaukrt@email.cz>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
GNU tee does this only with -p, which we don't have yet.
function old new delta
tee_main 306 295 -11
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Without the 'U' unsigned suffix, gcc will throw a "integer constant is
so large that it is unsigned" warning.
Signed-off-by: Kang-Che Sung <explorer09@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Some hosting services like sourceforge perform a lot of relocations
before actually serving the file. Example of current limitation:
busybox wget http://sourceforge.net/projects/fluxbox/files/fluxbox/1.3.7/fluxbox-1.3.7.tar.xz
Connecting to sourceforge.net (216.105.38.13:80)
Connecting to sourceforge.net (216.105.38.13:443)
Connecting to sourceforge.net (216.105.38.13:443)
Connecting to sourceforge.net (216.105.38.13:443)
Connecting to downloads.sourceforge.net (216.105.38.13:443)
wget: too many redirections
Signed-off-by: David Demelier <markand@malikania.fr>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>