From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33200) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zzs8F-0003Ia-E0 for qemu-devel@nongnu.org; Fri, 20 Nov 2015 15:18:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zzs8A-0003Ee-Fq for qemu-devel@nongnu.org; Fri, 20 Nov 2015 15:18:07 -0500 Received: from mail-wm0-x230.google.com ([2a00:1450:400c:c09::230]:32987) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zzs8A-0003Ea-AA for qemu-devel@nongnu.org; Fri, 20 Nov 2015 15:18:02 -0500 Received: by wmec201 with SMTP id c201so87552816wme.0 for ; Fri, 20 Nov 2015 12:18:01 -0800 (PST) Sender: Paolo Bonzini References: <1448010269-21694-1-git-send-email-pbonzini@redhat.com> <1448010269-21694-3-git-send-email-pbonzini@redhat.com> <564F6639.3080007@redhat.com> From: Paolo Bonzini Message-ID: <564F7FF2.9000509@redhat.com> Date: Fri, 20 Nov 2015 21:17:54 +0100 MIME-Version: 1.0 In-Reply-To: <564F6639.3080007@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 2/4] qjson: do not save/restore contexts List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake , qemu-devel@nongnu.org Cc: armbru@redhat.com On 20/11/2015 19:28, Eric Blake wrote: >> > + token = parser_context_peek_token(ctxt); >> > if (token == NULL) { >> > goto out; >> > } >> > >> > + if (token_get_type(token) != JSON_ESCAPE) { >> > + goto out; >> > + } > Could merge these two conditionals. Following the style of the rest of the file, for example: if (token == NULL) { goto out; } if (!token_is_operator(token, '{')) { goto out; } Paolo