From nobody Fri Apr 26 09:57:33 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1642081443; cv=none; d=zohomail.com; s=zohoarc; b=a/XpFrrNClCrQs8Xujc4agQQgdMWjt18EjBnIuXyB6V5emA7zb/ekTl7uSHm8PIbZh3VMv99+slDhJZ7b/CkXvEWP/KGrs2DRVyxhCOjKtDO3TP0zq+1NKmquKPA7QW7C4QTt1xQd/2NBvTiHjMTBSim1+z4sVRj5cWaRVJq6As= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642081443; h=Content-Type:Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=UY8i37g4Ogo6stft9V2Xz8i2GzhHqClrkDzcl0ZDyIk=; b=lTVSq+aF+Sv3t4uipShLoRi+xHASsdh++QLfrFvY1Gyy+1w+d+KDKTeVz9gwrPyVrMIxDZfdBBDgNNA5o4VDW8Q110HHNGkG3Twl6KUJqiowlbs9ppysEcNPz34JsgH5mDlLnV0+rEqo0IXzVelBXuMe/JOg2L783oXDq2UTO78= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1642081443066950.9939376594652; Thu, 13 Jan 2022 05:44:03 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-120-YA1GPaEGOU2_DLf8k24sFA-1; Thu, 13 Jan 2022 08:44:00 -0500 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C2C7310247A6; Thu, 13 Jan 2022 13:43:55 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 807AF1060065; Thu, 13 Jan 2022 13:43:55 +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 A5F664BB7C; Thu, 13 Jan 2022 13:43:54 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 20DDhqrH015981 for ; Thu, 13 Jan 2022 08:43:52 -0500 Received: by smtp.corp.redhat.com (Postfix) id B646E2027EB5; Thu, 13 Jan 2022 13:43:52 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast05.extmail.prod.ext.rdu2.redhat.com [10.11.55.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B21642026D6B for ; Thu, 13 Jan 2022 13:43:49 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 5F3EE801E95 for ; Thu, 13 Jan 2022 13:43:49 +0000 (UTC) Received: from mail-ed1-f70.google.com (mail-ed1-f70.google.com [209.85.208.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-329-Wxgi8bdvOkiz_gqje9UzOQ-1; Thu, 13 Jan 2022 08:43:48 -0500 Received: by mail-ed1-f70.google.com with SMTP id ec25-20020a0564020d5900b003fc074c5d21so5309673edb.19 for ; Thu, 13 Jan 2022 05:43:47 -0800 (PST) Received: from wheatley.localdomain (nat-pool-brq-t.redhat.com. [213.175.37.10]) by smtp.gmail.com with ESMTPSA id 27sm903522ejm.41.2022.01.13.05.43.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Jan 2022 05:43:46 -0800 (PST) Received: from wheatley.redhat.com (wheatley.k8r.cz [127.0.0.1]) by wheatley.localdomain (Postfix) with ESMTP id DE4B936DCBB0 for ; Thu, 13 Jan 2022 14:43:45 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1642081442; 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:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=UY8i37g4Ogo6stft9V2Xz8i2GzhHqClrkDzcl0ZDyIk=; b=fbq8Yi6BF9X2cLD0GYUMsHkpVbaX6TarotkAQ8Y6Wu6oAv05iYhDsDaVLZjw863Fza7Vr1 gUjT86cmPual+4bcOISnuVFn24LX1qUahi/U/qh33E8ImSCecRqEZ6KOpJi1LCdodSFXk3 e8PZYd4wlqg6P3tByiOPXQIQKPhUf1Q= X-MC-Unique: YA1GPaEGOU2_DLf8k24sFA-1 X-MC-Unique: Wxgi8bdvOkiz_gqje9UzOQ-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=UY8i37g4Ogo6stft9V2Xz8i2GzhHqClrkDzcl0ZDyIk=; b=veOt/BtP7iT6gj6cNrJgIDSMzREGqW6v0pduMmeYq+eZ9HfgHIMchgqWGgohR7tyAM /MMEelXswGNL6DBq1qmaKu91BuadcNzW/VX/+Zrl/Z6xuTd8k5qxXUi5OYcrZ+mFlOel 3f/ocAHiy1ZHbDDGZVMm2Lh1Wfh63rIi5x0qRjR0rw2pddkPr3xj5YsIySBHzZDqTPfv 1GR1VMIc8Ctvtb4ezWt0dLE5FU46yYHatQE1IQnATe6cusds+eO8K343eSxBn0gJXgk1 erXoDOp8JoiC0ecKEJqOiwAkMTC4SlqLbgJVxkIdUiZsDd323KO/L65s8X5QEijlvRiD DkZg== X-Gm-Message-State: AOAM530YQNZA1vyAoVg/LHBPO8UoFFE/0FAuk2COKH5JR4VUuzuzl0lW K94IqGN5dYf0eA4WYvWOww4xVjLKOxd50Ljzz6NMDGiTz7+jGjletal7DhD8GTNN53KLR7GOPaz 0S++XTFH21ODQUI/msZkZMgsE5nnvnL2BV885QRGYENn1Qae8pjjFayLSBl4PWK9A3NX2nRs= X-Received: by 2002:a17:906:8557:: with SMTP id h23mr2257121ejy.451.1642081426995; Thu, 13 Jan 2022 05:43:46 -0800 (PST) X-Google-Smtp-Source: ABdhPJxbQxo4YH5HbyRfabtsK/QKTj0yTCkDWIeqN0Yn/eD/+ILDTClBO9vsGN62pmdMZywMdBvkhg== X-Received: by 2002:a17:906:8557:: with SMTP id h23mr2257110ejy.451.1642081426702; Thu, 13 Jan 2022 05:43:46 -0800 (PST) From: Martin Kletzander To: libvir-list@redhat.com Subject: [PATCH] Print errors on daemon startup if logging setup fails Date: Thu, 13 Jan 2022 14:43:37 +0100 Message-Id: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 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.22 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) X-ZM-MESSAGEID: 1642081445659100001 Content-Type: text/plain; charset="utf-8" https://bugzilla.redhat.com/show_bug.cgi?id=3D2039652 Signed-off-by: Martin Kletzander Reviewed-by: J=C3=A1n Tomko --- src/locking/lock_daemon.c | 4 +++- src/logging/log_daemon.c | 4 +++- src/remote/remote_daemon.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/locking/lock_daemon.c b/src/locking/lock_daemon.c index ea81940a4325..75ebd059d79a 100644 --- a/src/locking/lock_daemon.c +++ b/src/locking/lock_daemon.c @@ -919,8 +919,10 @@ int main(int argc, char **argv) { config->log_outputs, privileged, verbose, - godaemon) < 0) + godaemon) < 0) { + virDispatchError(NULL); exit(EXIT_FAILURE); + } =20 if (!pid_file && virPidFileConstructPath(privileged, diff --git a/src/logging/log_daemon.c b/src/logging/log_daemon.c index fe7fa8534aec..8c3eb66895dc 100644 --- a/src/logging/log_daemon.c +++ b/src/logging/log_daemon.c @@ -725,8 +725,10 @@ int main(int argc, char **argv) { config->log_outputs, privileged, verbose, - godaemon) < 0) + godaemon) < 0) { + virDispatchError(NULL); exit(EXIT_FAILURE); + } =20 if (!pid_file && virPidFileConstructPath(privileged, diff --git a/src/remote/remote_daemon.c b/src/remote/remote_daemon.c index 84157e6cc19a..1b8e982a2f01 100644 --- a/src/remote/remote_daemon.c +++ b/src/remote/remote_daemon.c @@ -940,8 +940,10 @@ int main(int argc, char **argv) { config->log_outputs, privileged, verbose, - godaemon) < 0) + godaemon) < 0) { + virDispatchError(NULL); exit(EXIT_FAILURE); + } =20 /* Let's try to initialize global variable that holds the host's boot = time. */ if (virHostBootTimeInit() < 0) { --=20 2.34.1