Subject: Re: Deprecating SIOCGIFCONF
To: None <tls@rek.tjls.com>
From: Steven M. Bellovin <smb@cs.columbia.edu>
List: current-users
Date: 11/11/2007 16:40:17
On Sun, 11 Nov 2007 11:26:39 -0500
Thor Lancelot Simon <tls@rek.tjls.com> wrote:

> On Sun, Nov 11, 2007 at 09:38:44AM -0500, Greg Troxel wrote:
> > Matthias Scheler <tron@zhadum.org.uk> writes:
> > 
> > > On Fri, Nov 09, 2007 at 11:02:48PM +0100, Martin Husemann wrote:
> > >> Too bad we can't easily deprecate SIOCGIFCONF via some
> > >> compile/link time message and force conversion to getifaddrs(3).
> > >
> > > Can't we? We could write a wrapper for ioctl() which intercepts
> > > it.
> > 
> > We could, but that would be runtime, and it would slow down every
> > ioctl call, but perhaps not enough to matter.
> 
> But it might matter, too.  There are a few places where ioctl really
> needs to be fast.
> 
> Can we make the preprocessor emit a warning at compile time when it
> sees the macro?  There must be some scary GCC extension syntax to do
> that, right?
> 
I don't think that a preprocessor warning will help with pkgsrc; the
warning is likely to scroll past unless you're looking for it.


		--Steve Bellovin, http://www.cs.columbia.edu/~smb