Date: Wed, 27 Feb 2002 07:32:18 -0500 From: "Brian F. Feldman" <green@FreeBSD.org> To: Dima Dorfman <dd@FreeBSD.org> Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/lib/libc/gen getpeereid.3 getpeereid.c src/sbin/mountd mountd.c src/sys/kern kern_prot.c uipc_usrreq.c src/sys/netinet tcp_subr.c udp_usrreq.c src/sys/netinet6 udp6_usrreq.c src/sys/security/lomac kernel_socket.c src/sys/sys ... Message-ID: <200202271232.g1RCWIM99653@green.bikeshed.org> In-Reply-To: Message from Dima Dorfman <dd@FreeBSD.org> of "Tue, 26 Feb 2002 20:45:37 PST." <200202270445.g1R4jbv29875@freefall.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Dima Dorfman <dd@FreeBSD.org> wrote: > dd 2002/02/26 20:45:37 PST > > Modified files: > lib/libc/gen getpeereid.3 getpeereid.c > sbin/mountd mountd.c > sys/kern kern_prot.c uipc_usrreq.c > sys/netinet tcp_subr.c udp_usrreq.c > sys/netinet6 udp6_usrreq.c > sys/security/lomac kernel_socket.c > sys/sys ucred.h > usr.sbin/inetd builtins.c > Log: > Introduce a version field to `struct xucred' in place of one of the > spares (the size of the field was changed from u_short to u_int to > reflect what it really ends up being). Accordingly, change users of > xucred to set and check this field as appropriate. In the kernel, > this is being done inside the new cru2x() routine which takes a > `struct ucred' and fills out a `struct xucred' according to the > former. This also has the pleasant sideaffect of removing some > duplicate code. > > Reviewed by: rwatson I believe that when I looked at this "way back when", I decided two things. One the cr_version _really_ should have not changed, otherwise programs that used xucred will now get ENOMEM when trying to request them from the kernel, despite the interface not having actually changed. I believe I also wanted XUCRED_VERSION to 0 initially so that there would be no incompatibility with programs currently using it; you've done this, but if the first field has changed size, also, then that would gratuitously be incompatible with old programs. What's done is done now, I suppose, but in the future I'd appreciate if you could keep a closer eye out to not gratuitously changing interfaces. They have a history of hurting us a lot in certain cases, and keep in mind they may also be part of a larger interface (cf. xucred is part of export_args). -- Brian Fundakowski Feldman \'[ FreeBSD ]''''''''''\ <> green@FreeBSD.org <> bfeldman@tislabs.com \ The Power to Serve! \ Opinions expressed are my own. \,,,,,,,,,,,,,,,,,,,,,,\ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200202271232.g1RCWIM99653>