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 libc/18719] New: argp_help (): broken formatting of option descriptions


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

            Bug ID: 18719
           Summary: argp_help (): broken formatting of option descriptions
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
          Assignee: unassigned at sourceware dot org
          Reporter: simon at keinstein dot org
                CC: drepper.fsp at gmail dot com
  Target Milestone: ---

The formatting of option descriptions gets broken if the length of the
formatted output becomes too long.

Example1:

#include <argp.h>
#include <stdio.h>

int
main (int argc, char **argv)
{
  struct argp_option options[] = {
    {"option", 'o', NULL, 0, "description:\n1\n2\n3\n4\n5\n6"},
    NULL
  };

  struct argp argp = {options};

  argp_help (&argp, stdout, ARGP_HELP_LONG, "argp-bug1");

  return 0;
}

output:
                               -o, --option               description:
                             1
                             2
                             3
                             4
                             5
6

expected output:
  -o, --option               description:
                             1
                             2
                             3
                             4
                             5
                             6

-- 
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]