From nobody Mon Feb 9 19:06:41 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1594006952; cv=none; d=zohomail.com; s=zohoarc; b=nSUzLpu1QjfqYW4LG3E6C4GPiQfZocEhJ+Zharh3NhLcL9QlvA6MqNv8qzJxJFmKNGkGpBQ23eG0npDChpEOvrfroO9vf1QCPk5zhDaH8OBVroJnaVhgxM0D751MiUJI+A9JLPZr/JOKIHfKusm2BjTuH7Ip0KURmuYX/0MEmn0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1594006952; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=NVjXIGV6BzJT/kz1MDZTALZ/yKSNZFQEFqmyWWb6qJs=; b=OS+ffdyhSfijBPeP22ig+R0IwWDpGG7d1/HQz3yhcoSt0AjIkB8jauwNUHDFZjaEUn+dFjWRoWybAGLW4tbgp5iXx+oZreP17gy7wlElas24iQ1327kQgL8148yGEAm/HYLMqn4f+6GtpsKLi+wCDwkkJ8GRhXbMsK8lWPuv1y8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1594006952641535.9945274983802; Sun, 5 Jul 2020 20:42:32 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-194-LJSmllBgOUW_3LpEAYtmww-1; Sun, 05 Jul 2020 23:42:29 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 9041918FE873; Mon, 6 Jul 2020 03:42:23 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6DB162DE79; Mon, 6 Jul 2020 03:42:23 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 4189F180530D; Mon, 6 Jul 2020 03:42:23 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 0663gHCj004782 for ; Sun, 5 Jul 2020 23:42:17 -0400 Received: by smtp.corp.redhat.com (Postfix) id 5BD187AC9F; Mon, 6 Jul 2020 03:42:17 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-194.phx2.redhat.com [10.3.112.194]) by smtp.corp.redhat.com (Postfix) with ESMTP id 103A271678 for ; Mon, 6 Jul 2020 03:42:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594006951; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=NVjXIGV6BzJT/kz1MDZTALZ/yKSNZFQEFqmyWWb6qJs=; b=UuFGqXl8EY0NR+C4WPsRD6gXbLhAPwskcADvobwOeyd8bKNDPMB1WL3tNe+bh0T6HcqyUS sNCKexmAX85WLlxAg6muEM2+L+FdoVC4r/zx564uxxaIdOiVi1LhU4VD5c4lvpqtV1h4d8 nOaP0cxfyQAaIIUVbG3PebVKxev24bU= X-MC-Unique: LJSmllBgOUW_3LpEAYtmww-1 From: Laine Stump To: libvir-list@redhat.com Subject: [PATCH 26/32] network: eliminate unnecessary labels Date: Sun, 5 Jul 2020 23:41:21 -0400 Message-Id: <20200706034127.1117504-27-laine@redhat.com> In-Reply-To: <20200706034127.1117504-1-laine@redhat.com> References: <20200706034127.1117504-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Laine Stump Reviewed-by: J=C3=A1n Tomko --- src/network/bridge_driver.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 9f37d8f558..713763130b 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -1842,7 +1842,6 @@ networkRadvdConfContents(virNetworkObjPtr obj, { virNetworkDefPtr def =3D virNetworkObjGetDef(obj); g_auto(virBuffer) configbuf =3D VIR_BUFFER_INITIALIZER; - int ret =3D -1; size_t i; virNetworkIPDefPtr ipdef; bool v6present =3D false, dhcp6 =3D false; @@ -1859,10 +1858,8 @@ networkRadvdConfContents(virNetworkObjPtr obj, } =20 /* If there are no IPv6 addresses, then we are done */ - if (!v6present) { - ret =3D 0; - goto cleanup; - } + if (!v6present) + return 0; =20 /* create radvd config file appropriate for this network; * IgnoreIfMissing allows radvd to start even when the bridge is down @@ -1887,10 +1884,11 @@ networkRadvdConfContents(virNetworkObjPtr obj, virReportError(VIR_ERR_INTERNAL_ERROR, _("bridge '%s' has an invalid prefix"), def->bridge); - goto cleanup; + return -1; } if (!(netaddr =3D virSocketAddrFormat(&ipdef->address))) - goto cleanup; + return -1; + virBufferAsprintf(&configbuf, " prefix %s/%d\n" " {\n%s };\n", @@ -1903,9 +1901,7 @@ networkRadvdConfContents(virNetworkObjPtr obj, =20 *configstr =3D virBufferContentAndReset(&configbuf); =20 - ret =3D 0; - cleanup: - return ret; + return 0; } =20 =20 --=20 2.25.4