Ignore:
Timestamp:
2009-04-06T15:08:00Z (16 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
7b0297b
Parents:
a78d001
Message:

sync with kernel

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/libc/generic/io/printf_core.c

    ra78d001 r5b7f418  
    249249 */
    250250static int print_str(char *str, int width, unsigned int precision,
    251         uint32_t flags, printf_spec_t *ps)
     251    uint32_t flags, printf_spec_t *ps)
    252252{
    253253        if (str == NULL)
     
    297297 */
    298298static int print_wstr(wchar_t *str, int width, unsigned int precision,
    299         uint32_t flags, printf_spec_t *ps)
     299    uint32_t flags, printf_spec_t *ps)
    300300{
    301301        if (str == NULL)
    302302                return printf_putstr(nullstr, ps);
    303 
     303       
     304        if (*str == U_BOM)
     305                str++;
     306       
    304307        /* Print leading spaces. */
    305308        size_t strw = wstr_length(str);
    306309        if (precision == 0)
    307310                precision = strw;
    308 
     311       
    309312        /* Left padding */
    310313        count_t counter = 0;
     
    316319                }
    317320        }
    318 
     321       
    319322        /* Part of @a wstr fitting into the alloted space. */
    320323        int retval;
     
    322325        if ((retval = printf_wputnchars(str, size, ps)) < 0)
    323326                return -counter;
    324 
     327       
    325328        counter += retval;
    326 
     329       
    327330        /* Right padding */
    328331        while (width-- > 0) {
Note: See TracChangeset for help on using the changeset viewer.