bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] printf %ls/%lc/%Q fixes


From: Chet Ramey
Subject: Re: [PATCH] printf %ls/%lc/%Q fixes
Date: Mon, 23 Oct 2023 09:57:49 -0400
User-agent: Mozilla Thunderbird

On 10/21/23 8:40 PM, Grisha Levit wrote:
On Thu, Oct 19, 2023 at 8:23 PM Grisha Levit <grishalevit@gmail.com> wrote:
@@ -490,7 +491,10 @@ printf_builtin (WORD_LIST *list)
                     ws[0] = wc;
                     ws[1] = L'\0';

-                   r = printwidestr (start, ws, 1, fieldwidth, precision);
+                   if (wc == L'\0')
+                     r = printstr (start, ws, 1, fieldwidth, precision);

Sorry, printstr isn't expecting a wchar_t* arg so that could be something like:

r = printstr (start, "", 1, fieldwidth, precision);

No worries; I already got that one.

--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]