Date: Sat, 7 Sep 2002 01:29:39 +0300 From: Peter Pentchev <roam@ringlet.net> To: standards@FreeBSD.org Cc: "Chris S.J.Peron" <maneo@bsdpro.com>, Garrett Wollman <wollman@FreeBSD.org>, Mike Heffner <mikeh@FreeBSD.org>, Dag-Erling Smorgrav <des@ofug.org> Subject: glob(3) in -STABLE: PR bin/42275 Message-ID: <20020906222939.GE384@straylight.oblivion.bg>
next in thread | raw e-mail | index | archive | help
--S1BNGpv0yoYahz37 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, I've been sitting on PR bin/42275 for a week now, guess it's about time to take some action, if only requesting a discussion :) I've CC'd Garrett Wollman and Mike Heffner as people who were involved in the recent glob(3) overhaul in CURRENT, and DES as the OpenSSH maintainer. The problem: STABLE's glob(3) does not consider a 'no match' case to be an error; sftp(1) depends on it being an error, and reacts badly to the empty list returned instead. A few months ago, in the 4.6 release cycle, it was decided to patch sftp(1) for the time being, resulting in revision 1.1.1.1.2.2 of src/crypto/openssh/sftp-int.c. However, now the problem has resurfaced with the OpenSSH update to 3.4, and there are some additional circumstances to take into account, such as the fact that CURRENT now has a real POSIX-compatible glob(3), up to and including the GLOB_NOMATCH return value. The solutions, as I see them: #1 - do the 'hide head in sand' thing again, and patch STABLE's sftp-int.c file again. Pros: easy, been done before. Cons: gratuitious local patches, hard to maintain (as witnessed by the problem's reappearance). #2 - MFC the POSIX-compatible glob(3) in full. Pros: full POSIX compatibility in STABLE, proper GLOB_NOMATCH handling. Cons: API and ABI breakage for both the glob(3) error codes and general behavior; in addition, the MFC itself might not be quite trivial, what with the conditional preprocessor definitions. #3 - MFC a limited version of the glob(3) overhaul, only adding the GLOB_NOMATCH error code and handling. Pros: GLOB_NOMATCH handling in STABLE, working sftp(1) client. Cons: limited API and ABI incompatiblity for the glob(3) error codes - some programs may get an error code that did not exist at the time they were compiled. I wonder if this will indeed be a problem.. So.. opinions? I really hope this will be resolved in some way or other before 4.7 rolls out the door.. G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 The rest of this sentence is written in Thailand, on --S1BNGpv0yoYahz37 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (FreeBSD) iD8DBQE9eSxT7Ri2jRYZRVMRAr3/AKCndPLbvQo0aPkQQMqzEXhr5+sAZACfat2z XdHptgxgVT36l/5EwOrnRdo= =oce4 -----END PGP SIGNATURE----- --S1BNGpv0yoYahz37-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020906222939.GE384>