Ignore:
Timestamp:
2007-10-04T15:05:25Z (17 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
db25906
Parents:
1c38445
Message:

Fix the string printing precision bug also in the kernel.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/printf/printf_core.c

    r1c38445 rf7fad5a  
    198198        }
    199199
    200         while (precision > size) {
    201                 precision--;
    202                 if (printf_putchar(' ', ps) == 1)       
    203                         ++counter;
    204         }
    205        
    206         if ((retval = printf_putnchars(s, precision, ps)) < 0) {
     200        if ((retval = printf_putnchars(s, size < precision ? size : precision,
     201            ps)) < 0) {
    207202                return -counter;
    208203        }
Note: See TracChangeset for help on using the changeset viewer.