From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-vs1-xe2f.google.com (mail-vs1-xe2f.google.com [IPv6:2607:f8b0:4864:20::e2f]) by sourceware.org (Postfix) with ESMTPS id B4578384DD83 for ; Fri, 16 Dec 2022 21:50:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B4578384DD83 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-vs1-xe2f.google.com with SMTP id 128so3548125vsz.12 for ; Fri, 16 Dec 2022 13:50:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:reply-to:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=vDSs/uLdFAr/Yy9s4vPDcV5RwJtZ9OKgMvEOd7MxJ9U=; b=mYpONhGpQJqS5BmRhkCW86+GIWMNUtxFTzHGkJ5ZRILpVk9+f5Uy54u7HwaphMTntF 1HG5SzMQPc3eQ1e6YVJAuyi8QE5/X3PBaThwA5TmKGxcjc2b+0MJ3SVRbblL0q1X+x1n AtgekEV1KVm2mR+ecwWS9E5miWcSBnL/vi+0VQnR0Ew7n6L1+HP+mThCn63fYsm+36A3 jxfQu29x0yoRWcOF7CvEgtf3hllS+hHMGuqlAPm3CMnS9mtcfcCtYlXYV/nvrfvgtTDf sqWUsvUzs7t8tDEvIEyNvzWTxmRUQf8wF8qMm7eBeeqNmQ95U016VF4gEY8eyXWV+78r WQyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:reply-to:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=vDSs/uLdFAr/Yy9s4vPDcV5RwJtZ9OKgMvEOd7MxJ9U=; b=M7MK/e9AHlEZaGcVaIc1+r9QZOuygjcyDIwWQcFLmEtC0zzPvftF/r87ffUjEHSdY4 /gzMVNkp2vfnM7xIHVIvc6jQqz5HzeGv2q+PeIpLx9rygucYL/kcPL9cAHPL4gtB+UQe vOJwEJx9xeN8RIL6i6MkZFN/97RnZKD2zaNoZYy6qh1P5laHwZdB16Y5ntJpmnRzPCSm kLLxY+CzzjhkEVzKtKb111j9GBds3X0ORd4yYLBm1TvbuFR8RJcrCqI8zvugwqYQ4Hy8 EoiTInNFvA8kt3fX8woejqf3NdACZ5yh6rvJQHIOwmtJkofGH6rWrp/HIMLKzdAh4Wtn m4Ww== X-Gm-Message-State: ANoB5plnFbJ5w79ArPc2HPgyVU+BHqsgaODWzdNue+VC8+SWBhSW5jEN 8GtDZYWtq/E2Dr8edyHDs4A+LqFzV3Bvtrb3Sc196I15 X-Google-Smtp-Source: AA0mqf5GYaglKRjLqqFisKrMzE0/2YF5SKybevUktElUamMmqGUIjw+LjMpGKxkvpxcMdeR7V5N81TeTrg/53phS3J4= X-Received: by 2002:a05:6102:1493:b0:3b1:2b1d:cace with SMTP id d19-20020a056102149300b003b12b1dcacemr14945150vsv.26.1671227416098; Fri, 16 Dec 2022 13:50:16 -0800 (PST) MIME-Version: 1.0 References: <20221020182603.815-1-luoyonggang@gmail.com> <20221020182603.815-16-luoyonggang@gmail.com> In-Reply-To: Reply-To: luoyonggang@gmail.com From: =?UTF-8?B?572X5YuH5YiaKFlvbmdnYW5nIEx1byk=?= Date: Sat, 17 Dec 2022 05:50:04 +0800 Message-ID: Subject: Re: [PATCH 15/25] lib: Implement error properly even when not HAVE_ERR_H To: Mark Wielaard Cc: elfutils-devel@sourceware.org Content-Type: multipart/alternative; boundary="00000000000079bb9d05eff8f404" X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,BODY_8BITS,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --00000000000079bb9d05eff8f404 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Dec 12, 2022 at 11:37 PM Mark Wielaard wrote: > > Hi, > > On Fri, 2022-10-21 at 02:25 +0800, Yonggang Luo via Elfutils-devel > wrote: > > on win32, there is no err.h > > [...] > > +#else > > + (void)status; > > + vfprintf(stderr, format, argp); > > +#endif > > va_end(argp); > > That doesn't look like a valid implementation of error, it ignores > errno and doesn't exit when necessary. Do you mean it should call `exit(status)` after the error message is printed? > > Cheers, > > Mark -- =E6=AD=A4=E8=87=B4 =E7=A4=BC =E7=BD=97=E5=8B=87=E5=88=9A Yours sincerely, Yonggang Luo --00000000000079bb9d05eff8f404--