Re: [patch] arp.c spaces nested between tabs

2022-12-30 Thread Paul Tagliamonte
On Thu, Dec 29, 2022 at 09:52:49AM +0100, Omar Polo wrote:
> ksh actually supports that style of globbing :)

Fair enough! TIL -- but the GNU Grep bit stands, though :)


Any takers on the diff? Should be an easy one

  paultag

-- 
:wq



Re: [patch] arp.c spaces nested between tabs

2022-12-29 Thread Omar Polo
On 2022/12/28 12:21:07 -0500, Paul Tagliamonte  wrote:
> [2]: {openbsd monks avert your eyes: gnu grep and bash w/ 'shopt -s extglob'}:
>  $ grep -P '\t +\t' !(gnu|sys) -ril

ksh actually supports that style of globbing :)

% ls -d !(gnu|sys)
Makefiledistrib/include/regress/usr.bin/
Makefile.cross  etc/lib/sbin/   usr.sbin/
bin/games/  libexec/share/



[patch] arp.c spaces nested between tabs

2022-12-28 Thread Paul Tagliamonte
Hello, tech@!

Minor patch for `arp(8)`. It uses some spaces between two tabs that are
hard to notice. I have a syntax highlighting rule that shows such spaces[1]
so I saw it while reviewing the arp.c source.

I've learned my lesson trying to patch the monorepo across folder lines, so
here's a patch for only just arp.c, and a list of files that match a grep[2]
attached for someone else who feels the urge to be told off on the list -- I've
done exactly zero work to figure out if there's any false positives (spoiler,
there are just from scanning some of them) due to filetype[3] or source that's
not `style(9)` formatted yet; but I'll let someone else take that windmill on
if they're so inclined. I have become disinclined :)

Plus, I fear if I send another large diff after going through all these cases,
jmc@ won't have any free time this holiday season[4], and we can't have that.

```
Index: arp.c
===
RCS file: /cvs/src/usr.sbin/arp/arp.c,v
retrieving revision 1.88
diff -u -p -r1.88 arp.c
--- arp.c   16 Sep 2019 20:49:28 -  1.88
+++ arp.c   28 Dec 2022 04:49:15 -
@@ -418,7 +418,7 @@ tryagain:
if (sdl->sdl_family == AF_LINK && rtm->rtm_flags & RTF_LLINFO) {
if (rtm->rtm_flags & RTF_LOCAL)
return (0);
-   if (!(rtm->rtm_flags & RTF_GATEWAY))
+   if (!(rtm->rtm_flags & RTF_GATEWAY))
switch (sdl->sdl_type) {
case IFT_ETHER:
case IFT_FDDI:
```

   paultag


[1]: from my ~/.exrc for vim:
 highlight NestedSpace ctermbg=red ctermfg=white guibg=red
 match NestedSpace  /\t \+\t/

[2]: {openbsd monks avert your eyes: gnu grep and bash w/ 'shopt -s extglob'}:
 $ grep -P '\t +\t' !(gnu|sys) -ril

[3]: you can never be too sure; perhaps there's some whitespace
 (the language) source in-tree
 https://en.wikipedia.org/wiki/Whitespace_(programming_language)

[4]: if someone with eyes on jmc@ could give him some cookies as a thanks for
 his hard work, the universe would be very thankful.

-- 
:wq
bin/ed/ed.h
bin/ed/io.c
bin/ed/main.c
bin/csh/proc.c
distrib/notes/alpha/hardware
etc/etc.powerpc64/MAKEDEV
etc/etc.powerpc64/MAKEDEV.md
games/hack/hack.end.c
games/hack/hack.shk.c
games/bs/bs.c
games/atc/update.c
games/phantasia/phantstruct.h
games/cribbage/cribcur.h
games/backgammon/backgammon/move.c
games/canfield/canfield/canfield.c
include/rpc/auth_unix.h
include/protocols/talkd.h
include/Makefile
include/resolv.h
lib/libkeynote/keynote-ver.l
lib/libkeynote/keynote-verify.c
lib/libkeynote/keynote.l
lib/libkeynote/keynote.y
lib/libpcap/grammar.y
lib/libpcap/optimize.c
lib/libfido2/src/u2f.c
lib/libcurses/tinfo/MKfallback.sh
lib/libform/form.h
lib/libsndio/sio_aucat.c
lib/csu/hppa/md_init.h
lib/libcrypto/engine/eng_cnf.c
lib/libcrypto/sha/asm/sha1-586.pl
lib/libcrypto/modes/gcm128.c
lib/libcrypto/modes/cfb128.c
lib/libcrypto/objects/objects.txt
lib/libcrypto/perlasm/x86_64-xlate.pl
lib/libcrypto/x509/x509_pmaps.c
lib/libcrypto/x509/x509.h
lib/libcrypto/rsa/rsa_lib.c
lib/libcrypto/whrlpool/wp_dgst.c
lib/libcrypto/util/mkstack.pl
lib/libcrypto/aes/asm/bsaes-x86_64.pl
lib/libm/src/e_log.c
lib/libm/src/e_fmod.c
lib/libm/src/e_rem_pio2f.c
lib/libm/src/e_cosh.c
lib/libm/src/e_rem_pio2.c
lib/libm/src/e_lgammaf_r.c
lib/libm/src/s_log1pf.c
lib/libm/src/s_expm1f.c
lib/libm/src/e_atan2f.c
lib/libm/src/s_log1p.c
lib/libm/src/e_sinh.c
lib/libm/src/s_erf.c
lib/libm/src/e_jnf.c
lib/libm/src/e_logf.c
lib/libm/src/k_rem_pio2.c
lib/libm/src/e_atan2.c
lib/libm/src/e_remainderf.c
lib/libm/src/k_rem_pio2f.c
lib/libm/src/s_expm1.c
lib/libm/src/e_sqrt.c
lib/libm/src/e_jn.c
lib/libm/src/e_fmodf.c
lib/libm/src/k_cos.c
lib/libm/src/e_lgamma_r.c
lib/libm/src/k_tan.c
lib/libm/src/e_expf.c
lib/libm/src/e_atan2l.c
lib/libm/src/k_sin.c
lib/libc/db/btree/bt_split.c
lib/libc/db/hash/hash.h
lib/libc/gdtoa/ldtoa.c
lib/libc/arch/powerpc/string/memmove.S
lib/libc/arch/amd64/string/ffs.S
lib/libc/arch/powerpc64/string/memmove.S
lib/libc/arch/i386/string/ffs.S
lib/libc/stdlib/merge.c
lib/libc/stdlib/malloc.c
lib/libc/stdlib/getopt_long.3
lib/libc/time/localtime.c
lib/libc/stdio/fvwrite.c
lib/libc/stdio/vfwscanf.c
lib/libmenu/eti.h
lib/libssl/d1_both.c
lib/libssl/ssl3.h
lib/libssl/tls1.h
libexec/ld.so/aarch64/SYS.h
libexec/ld.so/riscv64/SYS.h
libexec/tradcpp/array.h
libexec/login_ldap/aldap.h
libexec/spamd/grey.c
regress/lib/libm/msun/ctrig_test.c
regress/lib/libm/msun/invctrig_test.c
regress/lib/libc/popen/popen.c
regress/lib/libc/arch/alpha/divremtest/divremtest.c
regress/sys/kern/unveil/syscalls.c
regress/usr.bin/ssh/unittests/misc/test_strdelim.c
regress/usr.bin/tsort/tsort-check
regress/usr.bin/openssl/appstest.sh
regress/usr.sbin/pkg_add/Makefile
regress/bin/ksh/bksl-nl.t
regress/bin/ksh/th
sbin/dhcpleased/parse.y
sbin/ipsecctl/parse.y