Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Apr 2010 12:24:46 -0700
From:      Xin LI <delphij@delphij.net>
To:        freebsd-ports@freebsd.org, freebsd-net@freebsd.org
Subject:   Recent nc(1) changes
Message-ID:  <4BC767FE.4060504@delphij.net>

next in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Thanks to Dima Panov, we have now figured out a behavior change that
could break some ports.  I'd like to give some more details for the record.

In the past, nc(1) would give a message like "Connection to xxx xxx port
[tcp/*] succeeded" if either -v or -z is specified in stdout.  In newer
nc(1) from OpenBSD, this has been changed to stderr.  In -CURRENT, we
have followed OpenBSD's behavior.  I think, that this behavior is more
sensible since one can, say, filter stdout and stderr to two
programs/logs to fill their need.

This unfortunately would break some ports that uses nc -z's standard
output as an indicator of whether the connection is succeeded.  To solve
this, one can modify the script to use "2>&1" when getting the output,
which is compatible to the old nc(1) as well.

Another change is that nc(1) now considers '-o' as deprecated.  My plan
is to remove this option before 9.0-RELEASE.  Will this removal be a
problem for anyone?

Cheers,
- -- 
Xin LI <delphij@delphij.net>	http://www.delphij.net/
FreeBSD - The Power to Serve!	       Live free or die
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (FreeBSD)

iQEcBAEBAgAGBQJLx2f+AAoJEATO+BI/yjfBkKMH/2R4J82mJkWJkddZ/XjlmoQq
VruKRMu06w3pXpqzMyqt0MXMII8v5x1jRrhusrZnNJ3dLXjpBHj9WqBYLVCskDdf
3etDE4gKK4DH2hhLuK4HOT4fM70OSN/18fDcpbZ7zrIRWoSheQXESZKy9po99y69
ENUhuxgyzDKzOqccArttJbiz6+jrcoDOjRf7ULnegIKaE4B58fAcpqO9A+6UZBHc
Rh2OdnQgYI2wpKxihZiklgK7VDQx09Qvl+4UacDC08uu7rBh3cD09UziQHGjnicV
MLhFSN/LGNNc2BVb0z4mFOtaP4efYu9Rxuyy1idOJCPg/HD/+2CECNlZm2BWRe8=
=azZK
-----END PGP SIGNATURE-----



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4BC767FE.4060504>