From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 20207 invoked from network); 6 May 2023 03:53:56 -0000 Received: from second.openwall.net (193.110.157.125) by inbox.vuxu.org with ESMTPUTF8; 6 May 2023 03:53:56 -0000 Received: (qmail 11905 invoked by uid 550); 6 May 2023 03:53:53 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 11873 invoked from network); 6 May 2023 03:53:52 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=s31663417; t=1683345221; i=nullplan@gmx.net; bh=cEXB+xIAd+D9a4k4YS1Y8zuu9BeFq3o+rvDy/EsnafA=; h=X-UI-Sender-Class:Date:From:To:Subject:References:In-Reply-To; b=B2aI4gqsUMGroYxjFVf4nKJYJYk/fep/d57cBsGUtEWSumQrEzs46rDWIytY0wwRP SmmtY4yUsUAH7PgCYKxbAyMBMFcOOX21iySnUlSzWQhHV9hujjzU9T01YIS1h8hQIE ZkbCovgWOrH2h0/ITR1gpdLYFedXvigOpHBmTTWv6Y0HTLQtgvmyIdDNYdaIyVYaxB zjXJgvNuy9oiYuwg0vuNp1mEmzPnXdlo0Nh41glziQDx4HSfobbI2RIf3T5U0B64pY 93HnbSYXCylmQ4yBM42PirS1mJVIDCfk0U2jrFyAq1bakkLVI7cUtweVnnYDC6UP2v 3LzZ7WgXHDdcw== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Date: Sat, 6 May 2023 05:53:40 +0200 From: Markus Wichmann To: musl@lists.openwall.com Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Provags-ID: V03:K1:LHqqub4DR9dw7LbwgS3bAqjjzAm67ZoqeeTEvfY+OEp1xmfGu0H t9qWQ4/PmtxDc31VSm6reIQXIKxAIOjMuTBjxG+D08renDwRMbjjavF0SYfVBJWeIDcmU2G tNgX14UMlG/N6xCtFph+CXyhL4EOcNIHMRX93kp+Fa25wVrsqO8YtAOJJF0L5LQbTdAnNBM J3fL5PeDaZaR4XF8DP1LQ== UI-OutboundReport: notjunk:1;M01:P0:TZKgbCK6c78=;aukqyIPWrn+LDch3r1V3CvSpgAy D3iDXLml6UnKsMWo2c/A0fKBO7cFlkFI8kv+tp5B/O95V4pAgENbXtSe1sP2R33/bsw1Z5FUF wsWmroNmiJ39T8oFVtNrtoO4yh943K5AHPXoKfHjYxHvZaH5xGtFg5KBIal57NYzkN/vGRkBH f1U5YDzSI0L3kuWAWQa8NXxzYQ+4utDJwHtGwx7oocUaylLND8LGEWAUdAp22bknTbyky31Bk NFb2lkWYtxD9MS9GMTdKFjXrHG4E9vIAUYcG8ghmcn4FyprCg4vb+I4IDnItD3tc1pvB8jC2n /QDpAJEAaLceFH4V3q4zt93OQLmlPXZ6HlTijGZ32KngtZeVuUesk2v7pn6Q9bzuA3nSsimQV mYKHDx5gnvFRVTCqKWVPgNs/d381DzrbdsAEbPoKz/3nfs1Hesm4HLfgY9XZSPluNf8rkKic+ Ule8B9oBRJ7GWie2dJ+QiAADf3keHI4WBRLI9vxclkKJk8jMkbil1LAc9vcVxge5hd7MRZbbh VHqxZACeuH1X1fDvLvGI+wcagy3dD/9Y+HJnmPq11kcMMCEK0wZro9bKOqM5wfRFP6KXOstaX JQLsqr+CYiua60ntKBPLqkBzBvE7Wg0wLkqjtrmDcI2fen9UNLc9xCNYko7pn6YNJUpagyA5h zfpUH8JD/JETHOd1UozFd9Oz5o57B3NQ7gZ0JLw91RximDaTk9AFzyTEMeElrHrKbticlt7vO zWGAJXoQ3s+7+n9bO3/SRz6UvEImErZ5lKYrTXUA7cNXJc7thozKidHAIFaln+oypazYVdKFF vvD4A/F8XBscNhdixyKE5cfMFXDiCf81dvyidh+eyk6h5ozWmRvFpTYCcRu3DAZecKgTSZ6v6 Opsio2oqTyHxsqZTWRsIT+BfBk3qjt5PyN9TP1D6zZCwOXaTFbOMGxv4yGeJMZmc3xs/N64c8 eG1Xk55/w95GOfiloezV4rv/G10= Subject: Re: [musl] Question: Why vfprintf call twice printf_core? Am Sat, May 06, 2023 at 11:29:36AM +0800 schrieb 847567161: > Hello, > I'm analyzing vfprintf performance, I don't know why musl call > "printf_core(0, fmt, &ap2, nl_arg, nl_type)" here. Could you > tell me the reason? > https://gitee.com/openharmony/third_party_musl/blob/master/src/stdio/vfprintf.c#L668 > More info: I use gdb to debug vfprintf , I found it return > directly when calling printf_core firstly which file parameter is > 0. > https://gitee.com/openharmony/third_party_musl/blob/master/src/stdio/vfprintf.c#L526 > Best Regards Chuang Yin First call to printf_core() checks to see if there are any major problems with the format string, and if the string is using positional arguments (e.g. "%2$d"), also establishes the types of these arguments and writes them into an array. Second call does the actual work. The shortcut after the first printf_core() call is an error exit. That means the format string is invalid. Could you tell us what the format string is in your case? Additionally, there is something weird with your mail client; it is writing HTML entities into the plain text. Ciao, Markus