From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTP id 420B85A004F for ; Mon, 05 Aug 2024 16:34:32 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1722868471; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=XHM6QgFRHV+rzFuxEp9s55LrVhLTwXlKdIIbfIRsslw=; b=Tlmy/15aJv8CM4RLkaK2J0EEM4Hd47QzKFb5/rDNomtDstcmDmLtMRI8DLuXUAApy2eSpS qxg7/gZqFhBiUCHcPMftDgfzZNirsLRLhNyJwULdKRUe1zc/d7s1AkXYSGJ2rVjLEAcV9f LwLMmwXeSKy2yzYdX0i9043ieVN1nfk= Received: from mail-lj1-f198.google.com (mail-lj1-f198.google.com [209.85.208.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-340-pptQrRMjNVqBgdupeQtwGQ-1; Mon, 05 Aug 2024 10:34:29 -0400 X-MC-Unique: pptQrRMjNVqBgdupeQtwGQ-1 Received: by mail-lj1-f198.google.com with SMTP id 38308e7fff4ca-2ef2fd50a2aso100597021fa.1 for ; Mon, 05 Aug 2024 07:34:29 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1722868467; x=1723473267; h=content-transfer-encoding:mime-version:organization:references :in-reply-to:message-id:subject:cc:to:from:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=XHM6QgFRHV+rzFuxEp9s55LrVhLTwXlKdIIbfIRsslw=; b=da3AkDNuGgZmgfSGZjIgVEyIiR2jd+DEtIiXM6+QQi2GJGRqkWRPYD/9iCKXmqct48 l1Vkhgfk12Xah5LS0lOKEAoNfvUnJ72hh2ZDtLyIXExmf2khRLELtSJhwKXhnOEUVQ+O Dcay56rpyza8PEfLYCEhVfsphTV3oTlMqDebM8Y4DtVJYpmfodPMRNcISdGFG/N41jG5 i02Z7hC4f38H18hG7nhBSrF3Z+MDZmvf2xQeCew2Bc8gSMI4mDr3an7mhel067SvlCt8 L6xKwCVF7KMrjwijKIMni1xzNv6fefKTWPTxf7PP/xXyhr87+W6X0ggbTM9BRPJlXCHO x8tw== X-Gm-Message-State: AOJu0Yx0rKIHhHRIevIkFM+U1c7NBbHMEmrXlFSsggwkFIV2LlDhToJY noCbhxZmH0BWT8E8conaeMSnF/exKPvDikK4OVTi2cVUnxOFU6oQXorRkl0Q1Aqqduqd1wYckM2 M+YfCeHpMelkYZHvBalf71YBEJgn14qV8LiAtSD3zfPK5Ihxll5xGjMA2efOSu27cH0XdnkXa86 YPYmFxbo5nHd36BnAtDgWheo+6G5BCxo0wzMM= X-Received: by 2002:a2e:9b0b:0:b0:2f0:2a55:8c4a with SMTP id 38308e7fff4ca-2f15ab53707mr80912851fa.49.1722868467020; Mon, 05 Aug 2024 07:34:27 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF3to2lUtRhUWAYR0EKU0ry+bFTpo/qTBfS7BnJpDlCowXBVrRHPuZiMg7orUaylcsqtVN+rQ== X-Received: by 2002:a2e:9b0b:0:b0:2f0:2a55:8c4a with SMTP id 38308e7fff4ca-2f15ab53707mr80912601fa.49.1722868466339; Mon, 05 Aug 2024 07:34:26 -0700 (PDT) Received: from maya.myfinge.rs (ifcgrfdd.trafficplex.cloud. [2a10:fc81:a806:d6a9::1]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-428e6e9d887sm140676435e9.43.2024.08.05.07.34.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Aug 2024 07:34:25 -0700 (PDT) Date: Mon, 5 Aug 2024 16:34:23 +0200 From: Stefano Brivio To: Laurent Vivier Subject: Re: [PATCH] util: In ASSERT(), use "fprintf(stderr, ...)" rather than err(...) Message-ID: <20240805163423.58f602f7@elisabeth> In-Reply-To: <20240805141027.1502569-1-lvivier@redhat.com> References: <20240805141027.1502569-1-lvivier@redhat.com> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.41; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: RQKZP6LRZXHWZ2HAWKVBOEGD26RUW7PV X-Message-ID-Hash: RQKZP6LRZXHWZ2HAWKVBOEGD26RUW7PV X-MailFrom: sbrivio@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: passt-dev@passt.top X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Mon, 5 Aug 2024 16:10:27 +0200 Laurent Vivier wrote: > We use our own implementation of assert() because the glic implementation > uses syscalls that aren't in our seccomp filter, see 7a8ed9459dfe > ("Make assertions actually useful"). And we replaced it by an err(), > followed by an abort() (that is also catched by seccomp). > We don't have a coredump or a backtrace but we have at least the > error message... only if logging is enabled. ...wait, err() should always end up somewhere (syslog, log file, or stderr). If you pick stderr, and we closed stderr, then the error will not be reported anywhere (or, possibly worse, on a socket that happens to have number 2). In which case are you losing messages? -- Stefano