|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 13/18] xenstored: support running in minios stubdom
Ian Campbell writes ("Re: [Xen-devel] [PATCH 13/18] xenstored: support running
in minios stubdom"):
> On Wed, 2012-01-18 at 17:13 +0000, Ian Jackson wrote:
> > I would normally prefer:
> >
> > > +#ifndef __MINIOS__
> > > static void write_pidfile(const char *pidfile)
> > > stuff
> > > }
> > > +#else
> > > +static void write_pidfile(const char *pidfile)
> > > +}
> > > +endif
>
> Yes, I'd normally do it this way too, not sure why I wrote the other...
>
> Only real difference is that it prevents the prototype getting out of
> sync and bit-rotting the infrequently used case if there is one.
Better that the prototype gets out of sync and you get a compiler
error, than that the prototype is updated but the little-used
implementations of the body of the function is not adjusted for new
semantics implied by new arguments ...
Ian.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |