From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Jackson Subject: Re: [PATCH 13/18] xenstored: support running in minios stubdom Date: Tue, 24 Jan 2012 16:24:57 +0000 Message-ID: <20254.56153.506648.395280@mariner.uk.xensource.com> References: <1326302490-19428-1-git-send-email-dgdegra@tycho.nsa.gov> <1326411330-7915-1-git-send-email-dgdegra@tycho.nsa.gov> <1326411330-7915-14-git-send-email-dgdegra@tycho.nsa.gov> <1326886420.14689.206.camel@zakaz.uk.xensource.com> <20246.64955.717774.909586@mariner.uk.xensource.com> <1326908107.14689.298.camel@zakaz.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1326908107.14689.298.camel@zakaz.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Ian Campbell Cc: Daniel De Graaf , "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org 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.