From: Ian Campbell Subject: Re: [PATCH] libxl: Cleanup, use LOG*, GCSPRINTF and CTX macros in libxl_device.c Date: Tue, 5 Nov 2013 13:56:14 +0000 Message-ID: <1383659774.13961.72.camel@kazak.uk.xensource.com> References: <1383588404-14328-1-git-send-email-alexandrasava18@gmail.com> <9afa7710aa5abd6bbf961c02c599a11d85012d08.1383600818.git.alexandrasava18@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: George Dunlap Cc: Anthony PERARD , Ian Jackson , Alexandra Sava , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org On Tue, 2013-11-05 at 11:48 +0000, George Dunlap wrote: > > bad_format: > > - LIBXL__LOG(ctx, LIBXL__LOG_DEBUG, "Disk vdev=%s, backend %s" > > - " unsuitable due to format %s", > > - a->disk->vdev, > > - libxl_disk_backend_to_string(backend), > > - libxl_disk_format_to_string(a->disk->format)); > > + LOG(DEBUG, "Disk vdev=%s, backend %s unsuitable due to format %s", > > + a->disk->vdev, > > + libxl_disk_backend_to_string(backend), > > + libxl_disk_format_to_string(a->disk->format)); > > Given that in existing places, the LOG macro has formatted variables > aligned to the beginning of the quote rather than to the open paren, There's a bit of a mixture and the indented version is more prevalent. But there's only 7 multiline uses of LOG* in that file (the split is 5:2 in favour of indentation). I'd object to just reindenting but if the line is changing anyway I have no strong feelings on the style used. The non-indented variant does have the benefit that formatting helpers (e.g. emacs' c-mode) do it that way for you... Ian.