[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH] libxl: Introduce LIBXL_DOMAIN_TYPE_INVALID to make gcc happy
Dario Faggioli writes ("Re: [Xen-devel] [PATCH] libxl: Introduce LIBXL_DOMAIN_TYPE_INVALID to make gcc happy"): > On Wed, 2012-05-23 at 11:53 +0100, Ian Jackson wrote: > > And the upside of making it be an enum is precisely > > > > > On Fri, 2012-05-18 at 15:48 +0100, Dario Faggioli wrote: > > > > _libxl_types.c: In function âlibxl_domain_build_info_disposeâ: > > > > _libxl_types.c:91:5: error: enumeration value > > > > âLIBXL_DOMAIN_TYPE_INVALIDâ not handled in switch [-Werror=switch] > > > > these warnings, which are alerting us to call sites with broken error > > handling. > > I agree, and I can sue try looking at those call sites and see what it > takes to add a proper 'case' or 'default' clause in there if you think > that to be the way to go... I think that would be best, if you're willing, thanks. I would recommend the use of "case" rather than "default" clauses in this case. That way if we introduce a new domain type the compiler will spot all the missing places for us. Ian. _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |