This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug stdio/21986] New: __guess_grouping is called incorrectly


https://sourceware.org/bugzilla/show_bug.cgi?id=21986

            Bug ID: 21986
           Summary: __guess_grouping is called incorrectly
           Product: glibc
           Version: 2.27
            Status: NEW
          Severity: normal
          Priority: P2
         Component: stdio
          Assignee: unassigned at sourceware dot org
          Reporter: hjl.tools at gmail dot com
  Target Milestone: ---

stdlib/strfmon_l.c has

     /* If we have to print the digits grouped determine how many
         extra characters this means.  */
      if (group && left_prec != -1) 
        left_prec += __guess_grouping (left_prec,
                                       _NL_CURRENT (LC_MONETARY, MON_GROUPING),
                                       *_NL_CURRENT (LC_MONETARY,
                                                     MON_THOUSANDS_SEP));

But __guess_grouping is defined in stdio-common/printf_fp.c as

unsigned int
__guess_grouping (unsigned int intdig_max, const char *grouping)
{

So the 3rd argument passed to __guess_grouping is ignored.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]