On Sunday 05 December 2010 10:00, Lauri Kasanen wrote:
> -             } else if (*here >= ' ' && *here <= '~') {
> +             } else if (*here >= ' ' && *here < 0x7f) {
> 
> This makes it less readable. Why replace the char with a hex value?

It is less obvious that '~' is the last ASCII character.

> -     if (argc > 1) bb_show_usage();
> -     else if (argc == 1) {
> -             if (*argv[0] >= '0' && *argv[0] <= '9') {
> +     if (argv[0]) {
> 
> I've been meaning to ask you about this. When I try to do the same,
> I end up usually getting a segfault. That was before any getopt too, maybe 
> that has an effect.

It should not segfault. Can you reproduce SEGV?

> -     G.output_width = 132;
> 
> By removing the default, what happens if get_terminal_width_height can't 
> get the real width?

get_terminal_width_height returns 80 for width if it fails to determine it.

-- 
vda
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to