Tested both regular options and long options against ISC's dhcpd, looks
good.
Martin
On Thu, 13 Aug 2020 at 10:00, Denys Vlasenko
wrote:
> On Tue, Aug 4, 2020 at 5:25 PM Martin Lewis
> wrote:
> > Duplicate options are currently overridden (only the last option is
> kept).
busybox_unstripped
Signed-off-by: Martin Lewis
---
networking/udhcp/dhcpc.c | 125 ++-
networking/udhcp/dhcpc.h | 1 +
2 files changed, 93 insertions(+), 33 deletions(-)
diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c
index 50dfead63..d4a7a825e
159915 159920 +5
> lsscsi_main 364 349 -15
>
> --
> (add/remove: 0/0 grow/shrink: 1/1 up/down: 5/-15) Total: -10
> bytes
>textdata bss dec hex filenam
Please note that my original patch is still smaller:
http://lists.busybox.net/pipermail/busybox/2020-June/088026.html
I'm not sure whether it's faster, it would be interesting to compare them.
On Tue, 7 Jul 2020 at 14:17, Tito wrote:
> Hi,
> attached you will find a patch that shrinks libbb's
bss dec hex filename
981645 169151872 1000432 f43f0 busybox_old
981603 169151872 1000390 f43c6 busybox_unstripped
Signed-off-by: Martin Lewis
---
networking/udhcp/domain_codec.c | 157
1 file changed, 79 insertions(+), 78
Thank you for applying the commits!
I started implementing support for RFC 3396, hopefully it will be ready
soon.
Martin
On Mon, 29 Jun 2020 at 08:40, Denys Vlasenko
wrote:
> Applied, thanks
>
> On Tue, Jun 23, 2020 at 3:41 PM Martin Lewis
> wrote:
> >
> > fil
;
}
return NULL;
}
On Tue, 30 Jun 2020 at 10:59, Jody Bruchon wrote:
> strlen scans the string; strrchr also scans the string.
>
> On 2020-07-01 10:23, Martin Lewis wrote:
> > Hi,
> >
> > I'm not sure what I'm missing, from a quick glance at strrchr
> > (g
t 3:45 PM Martin Lewis
> wrote:
> >
> > function old new delta
> > last_char_is 53 30 -23
> >
> ---
Up until now, udhcpc iterated over the received packet a few hundred times (!).
This patch series resolves the relevant TODO - iterating over the packet just
once,
while also reducing binary size.
Tested against:
* VMware's dhcp server
* udhcpd
* ISC's dhcpd
function
fill_envp now iterates over the packet only once instead of a few hundred times
using the new option scanner.
Signed-off-by: Martin Lewis
---
networking/udhcp/dhcpc.c | 201 ---
1 file changed, 87 insertions(+), 114 deletions(-)
diff --git
Added an option scanner to udhcp to enable iteration over packet options.
Signed-off-by: Martin Lewis
---
networking/udhcp/common.c | 96 ++-
networking/udhcp/common.h | 8
2 files changed, 62 insertions(+), 42 deletions(-)
diff --git
1000119 f42b7 busybox_old
981322 169151872 1000109 f42ad busybox_unstripped
Signed-off-by: Martin Lewis
---
miscutils/lsscsi.c | 50 ++
1 file changed, 34 insertions(+), 16 deletions(-)
diff --git a/miscutils/lsscsi.c b/miscutils/lsscsi.c
: 0/0 grow/shrink: 0/1 up/down: 0/-10) Total: -10 bytes
textdata bss dec hex filename
981342 169151872 1000129 f42c1 busybox_old
981332 169151872 1000119 f42b7 busybox_unstripped
Signed-off-by: Martin Lewis
---
libbb/compare_string_array.c | 7
bytes
textdata bss dec hex filename
981322 169151872 1000109 f42ad busybox_old
981299 169151872 186 f4296 busybox_unstripped
Signed-off-by: Martin Lewis
---
libbb/last_char_is.c | 9 -
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git
--
(add/remove: 1/0 grow/shrink: 0/1 up/down: 37/-113) Total: -76 bytes
textdata bss dec hex filename
981418 169151872 1000205 f430d busybox_old
981342 169151872 1000129 f42c1 busybox_unstripped
Signed-off-by: Martin Lewis
---
libbb/procps.c | 12
Hi,
Yes, looks good :)
Martin
On Wed, 10 Jun 2020 at 10:21, Denys Vlasenko
wrote:
> Thanks. I addressed this a bit differently. Looks good now?
>
> On Tue, Jun 9, 2020 at 4:55 PM Martin Lewis
> wrote:
> >
> > The only call to dname_enc is with cstr = NULL, so mos
textdata bss dec hex filename
993252 169231872 1012047 f714f busybox_old
993117 169231872 1011912 f70c8 busybox_unstripped
Signed-off-by: Martin Lewis
---
networking/udhcp/common.h | 2 +-
networking/udhcp/dhcpc.c | 47
) Total: -272
bytes
textdata bss dec hex filename
993252 169231872 1012047 f714f busybox_old
992980 169231872 1011775 f703f busybox_unstripped
Signed-off-by: Martin Lewis
---
networking/udhcp/common.c | 6 +-
networking/udhcp/common.h | 1
Hello,
Just a friendly ping for some old binary/code shrinking patches.
dhcpc:
http://lists.busybox.net/pipermail/busybox/2020-May/087942.html
xfuncs_printf.c:
http://lists.busybox.net/pipermail/busybox/2020-March/087822.html
function
Hello,
Sounds like you need output redirection.
You need to create a pipe, dup2 it over stdout, call lbb_main, and
read the output from
the pipe.
Similar question:
https://stackoverflow.com/questions/17071702/c-language-read-from-stdout
Martin
On 22/05/2020, Tiago Araujo da costa wrote:
> I
Hi,
/etc/profile is read only during interactive login shell mode (hush's -l
flag).
I think that a tty must be attached to the shell for this to work, not sure
if that's the case with inittab.
Martin
On Wed, 26 Feb 2020 at 18:37, Carlos Eduardo de Paula
wrote:
> I've been struggling to
Hello,
I have a few notes.
First of all, you should send the diff as a git patch. Not only will it
make the code much easier to read, but will also make it possible to commit
into the git repository.
Also you mentioned that the server still doesn't respond as expected,
perhaps you could address
--
(add/remove: 0/0 grow/shrink: 0/1 up/down: 0/-15) Total: -15 bytes
textdata bss dec hex filename
993144 169151872 1011931 f70db busybox_old
993129 169151872 1011916 f70cc busybox_unstripped
Signed-off-by: Martin Lewis
---
networking
Used the same function instead of strndup by mistake... Here's the correct
version:
Signed-off-by: Martin Lewis
---
libbb/xfuncs_printf.c | 19 +--
1 file changed, 5 insertions(+), 14 deletions(-)
diff --git a/libbb/xfuncs_printf.c b/libbb/xfuncs_printf.c
index 93f325c62
Signed-off-by: Martin Lewis
---
libbb/xfuncs_printf.c | 19 +--
1 file changed, 5 insertions(+), 14 deletions(-)
diff --git a/libbb/xfuncs_printf.c b/libbb/xfuncs_printf.c
index 93f325c62..b85dde797 100644
--- a/libbb/xfuncs_printf.c
+++ b/libbb/xfuncs_printf.c
@@ -93,26 +93,17
Signed-off-by: Martin Lewis
---
networking/nc_bloaty.c | 21 -
1 file changed, 4 insertions(+), 17 deletions(-)
diff --git a/networking/nc_bloaty.c b/networking/nc_bloaty.c
index 034e03d21..190a8bcb1 100644
--- a/networking/nc_bloaty.c
+++ b/networking/nc_bloaty.c
@@ -237,24
Signed-off-by: Martin Lewis
---
networking/nc_bloaty.c | 21 -
1 file changed, 4 insertions(+), 17 deletions(-)
diff --git a/networking/nc_bloaty.c b/networking/nc_bloaty.c
index 034e03d21..9848ea794 100644
--- a/networking/nc_bloaty.c
+++ b/networking/nc_bloaty.c
@@ -237,24
er the local "Erase Character"
> function is.
And from what I've seen from a couple of telnet servers (busybox excluded),
they support it.
On Fri, 18 Oct 2019 at 09:47, Denys Vlasenko
wrote:
> On Mon, Jul 8, 2019 at 4:38 PM Martin Lewis
> wrote:
> > Closes ht
A ping out of curiosity...
On Thu, 10 Oct 2019 at 16:33, Martin Lewis wrote:
>
> Hello,
>
> Could you please elaborate on what was lacking in the INT_MAX part?
> As seen in write's man page:
> >
> > On Linux, write() (and similar system calls) will transfer at most
&g
A friendly ping for an old patch.
On Mon, 8 Jul 2019 at 09:37, Martin Lewis wrote:
>
> Closes https://bugs.busybox.net/show_bug.cgi?id=11976
>
> Adds a new flag in telnet client's command line, which
> forces telnet to send IAC's instead of the
> traditional special cha
is is true on
>both 32-bit and 64-bit systems.)
Wouldn't it create an issue with 64 bit systems when trying to
read/write large files?
Thanks,
Martin
On Wed, 9 Oct 2019 at 07:37, Denys Vlasenko wrote:
>
> On Sun, Sep 15, 2019 at 6:14 PM Martin Lewis
> wrote:
> >
> >
Signed-off-by: Martin Lewis
---
networking/brctl.c | 217 -
1 file changed, 216 insertions(+), 1 deletion(-)
diff --git a/networking/brctl.c b/networking/brctl.c
index ba5b6226f..cb55b0c90 100644
--- a/networking/brctl.c
+++ b/networking
,
will you be able to please provide an example / code reference in
which the above code breaks (as I couldn’t find any)?
Thank you,
Martin
On Mon, 16 Sep 2019 at 07:54, Bernhard Reutner-Fischer
wrote:
>
> On 15 September 2019 18:04:49 CEST, Martin Lewis
> wrote:
> >Signed-off-b
If sub is empty, avoids an infinite loop.
Signed-off-by: Martin Lewis
---
libbb/replace.c | 4
1 file changed, 4 insertions(+)
diff --git a/libbb/replace.c b/libbb/replace.c
index a661d96..6183d3e 100644
--- a/libbb/replace.c
+++ b/libbb/replace.c
@@ -11,14 +11,18 @@
#include "li
platforms.
Signed-off-by: Martin Lewis
---
include/libbb.h| 14 ++
libbb/read.c | 15 +--
libbb/safe_write.c | 3 +++
3 files changed, 30 insertions(+), 2 deletions(-)
diff --git a/include/libbb.h b/include/libbb.h
index 111d1b7..07b1d05 100644
--- a/include
Noticed just now the problematic indentation. I'll fix it in a second,
sorry for the inconvenience.
___
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox
platforms.
Signed-off-by: Martin Lewis
---
include/libbb.h| 14 ++
libbb/read.c | 15 +--
libbb/safe_write.c | 3 +++
3 files changed, 30 insertions(+), 2 deletions(-)
diff --git a/include/libbb.h b/include/libbb.h
index 111d1b7..07b1d05 100644
--- a/include
Signed-off-by: Martin Lewis
---
networking/brctl.c | 119 -
1 file changed, 100 insertions(+), 19 deletions(-)
diff --git a/networking/brctl.c b/networking/brctl.c
index 586ca9b..35771a5 100644
--- a/networking/brctl.c
+++ b/networking/brctl.c
Signed-off-by: Martin Lewis
---
networking/udhcp/arpping.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/networking/udhcp/arpping.c b/networking/udhcp/arpping.c
index a395e83..59c2bf8 100644
--- a/networking/udhcp/arpping.c
+++ b/networking/udhcp/arpping.c
@@ -80,8 +80,7
telnet servers.
Currently only backspace is supported,
I will add support for other characters soon.
Signed-off-by: Martin Lewis
---
networking/telnet.c | 40 ++--
1 file changed, 34 insertions(+), 6 deletions(-)
diff --git a/networking/telnet.c b/networking
Resolved a TODO by adding support for gateway_nip parameter.
Signed-off-by: Martin Lewis
---
networking/udhcp/dhcpc.c | 13 +
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c
index 739870b..acd80f9 100644
)]))
^
Also fixed a possible alignment issue related to strict aliasing.
Signed-off-by: Martin Lewis
---
networking/udhcp/d6_common.h | 2 +-
networking/udhcp/d6_dhcpc.c | 4 ++--
2 files changed, 3 insertions(+), 3
You're absolutely right, I'll fix this right away.
On Thu, 4 Apr 2019 at 15:46, Denys Vlasenko
wrote:
> On Thu, Apr 4, 2019 at 1:33 PM Martin Lewis
> wrote:
> >
> > Fixed a TODO in AYT IAC handling by replying back with a NOP.
> >
> > Signed-off-by: Martin
Fixed a TODO in AYT IAC handling by replying back with a NOP.
Signed-off-by: Martin Lewis
---
networking/telnetd.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/networking/telnetd.c b/networking/telnetd.c
index caef151..c6fe815 100644
--- a/networking/telnetd.c
happy with this approach either...
> ...probably need to rewrite existing code to get rid of fgets(),
> use poll() + read().
>
From 3d70e006affde33a9b278b2a62c81d4eb40f2394 Mon Sep 17 00:00:00 2001
From: Martin Lewis
Date: Wed, 23 Jan 2019 15:46:16 +0100
Subject: [PATCH 1/2] wget: replace set_alarm
Replace die handlers with error returning so download_one_url can retry
from the beginning.
When retries is 1 (default) the behaviour should be the same as before.
v2: updated diff to mind the -o option, prettified help
Signed-off-by: Martin Lewis
---
networking/wget.c | 125
When printing notification on download start and end,
mistakenly, it didn't respect the quiet option
Signed-off-by: Martin Lewis
---
networking/wget.c | 23 ++-
1 file changed, 14 insertions(+), 9 deletions(-)
diff --git a/networking/wget.c b/networking/wget.c
index 3a02de6
Thank you
I have noticed that mistakenly the last patch doesn't respect the quiet
option, so I'm sending a fix
On Fri, 4 Jan 2019 at 18:28, Denys Vlasenko
wrote:
> On Wed, Dec 26, 2018 at 4:28 PM Martin Lewis
> wrote:
> > When using -o to file the progress meter is not display
Signed-off-by: Martin Lewis
---
networking/wget.c | 28 +---
1 file changed, 25 insertions(+), 3 deletions(-)
diff --git a/networking/wget.c b/networking/wget.c
index 58a51d9..8da0ce8 100644
--- a/networking/wget.c
+++ b/networking/wget.c
@@ -128,9 +128,10 @@
/* //usage
When using -o to file the progress meter is not displayed, so write that
we started the download and that we finished it.
Signed-off-by: Martin Lewis
---
networking/wget.c | 8
1 file changed, 8 insertions(+)
diff --git a/networking/wget.c b/networking/wget.c
index 8da0ce8..914221c
Hello,
These patches add the -t (--tries) option to wget.
There was an issue that wget died on errors, so I had to change some
functions to return error so we are able to retry.
Also I had to replace the blocking functions (and the set_alarm) with time
outing functions (in first patch).
In order
Replace die handlers with error returning so download_one_url can retry from
the beginning.
When retries is 1 (default) the behaviour should be the same as before.
Signed-off-by: Martin Lewis
---
networking/wget.c | 120 ++
1 file changed, 95
Signed-off-by: Martin Lewis
---
networking/wget.c | 162 +++---
1 file changed, 153 insertions(+), 9 deletions(-)
diff --git a/networking/wget.c b/networking/wget.c
index 58a51d9..e9fdd9f 100644
--- a/networking/wget.c
+++ b/networking/wget.c
53 matches
Mail list logo