public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
@ 2012-10-10  9:39 lascania at gmail dot com
  2012-10-10  9:43 ` [Bug manual/14695] " lascania at gmail dot com
                   ` (22 more replies)
  0 siblings, 23 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10  9:39 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

             Bug #: 14695
           Summary: Wrong printf("%3s"...) Example --- manual subsection
                    "12.12.6 Other Output Conversions"
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: minor
          Priority: P2
         Component: manual
        AssignedTo: unassigned@sourceware.org
        ReportedBy: lascania@gmail.com
                CC: mtk.manpages@gmail.com, roland@gnu.org
    Classification: Unclassified


Created attachment 6678
  --> http://sourceware.org/bugzilla/attachment.cgi?id=6678
picture of the manual page with wrong printf() example

glibc manual chapter "12. I/O on Streams"
section "12.12 Formatted Output"
subsection "12.12.6 Other Output Conversions" contains the following example
line:
"printf ("%3s%-6s", "no", "where");"

this example is incorrect because there are two missing dots that are used to
specify the precision of the output, how may characters printf() outputs.

The correct version is:
"printf ("%.3s%-.6s", "no", "where");"

observe the dot inside %.3s and the second dot inside %-.6s !



Check the attached .gif image for better clarification !

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
@ 2012-10-10  9:43 ` lascania at gmail dot com
  2012-10-10  9:46 ` lascania at gmail dot com
                   ` (21 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10  9:43 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Attachment #6678|picture of the manual page  |.GIF picture of the manual
        description|with wrong printf() example |page with wrong printf()
                   |                            |example

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
  2012-10-10  9:43 ` [Bug manual/14695] " lascania at gmail dot com
@ 2012-10-10  9:46 ` lascania at gmail dot com
  2012-10-10 10:01 ` schwab@linux-m68k.org
                   ` (20 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10  9:46 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                URL|                            |http://www.gnu.org/software
                   |                            |/libc/manual/html_node/Othe
                   |                            |r-Output-Conversions.html#O
                   |                            |ther-Output-Conversions

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
  2012-10-10  9:43 ` [Bug manual/14695] " lascania at gmail dot com
  2012-10-10  9:46 ` lascania at gmail dot com
@ 2012-10-10 10:01 ` schwab@linux-m68k.org
  2012-10-10 10:28 ` lascania at gmail dot com
                   ` (19 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-10 10:01 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Schwab <schwab@linux-m68k.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID

--- Comment #1 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-10 10:00:45 UTC ---
printf ("%.3s%-.6s", "no", "where") does not produce " nowhere ".

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (2 preceding siblings ...)
  2012-10-10 10:01 ` schwab@linux-m68k.org
@ 2012-10-10 10:28 ` lascania at gmail dot com
  2012-10-10 10:42 ` schwab@linux-m68k.org
                   ` (18 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10 10:28 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #2 from R N Alx <lascania at gmail dot com> 2012-10-10 10:28:12 UTC ---
Mr Schwab,

This example code, is not my own, not-my-own example !
printf ("%3s%-6s", "no", "where")

this example is writen in the manual, it is writen wrong inside the online
manual.

I filled this bug because I want the online manual subsection "12.12.6 Other
Output Conversions" to be changed because of two reasons:

1. reason one

there are missing two dots, %3.s and %-.6s

2. reason two

printf ("%.3s%-.6s", "no", "where") does YES YES YES produce " nowhere ".
but not because of the output conversion arguments .3 and -.6, but because
these two strings are only two characters and five characters long, thus the
output conversion arguments .3 and -.6 have no influence

but if the online manual is changed to:
printf ("%.3s%-.6s", "noOoO", "whereEeEeEeE")
the result will be " noOwhereE "

which is what the online manual is trying to explain how printf() is using
output conversion arguments to cut strings


CHECK THE .GIF IMAGE
http://sourceware.org/bugzilla/attachment.cgi?id=6678

CHECK THE ONLINE MANUAL
http://www.gnu.org/software/libc/manual/html_node/Other-Output-Conversions.html#Other-Output-Conversions

Thanx

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (3 preceding siblings ...)
  2012-10-10 10:28 ` lascania at gmail dot com
@ 2012-10-10 10:42 ` schwab@linux-m68k.org
  2012-10-10 10:58 ` lascania at gmail dot com
                   ` (17 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-10 10:42 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Schwab <schwab@linux-m68k.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID

--- Comment #3 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-10 10:42:03 UTC ---
printf ("%.3s%-.6s", "no", "where") does not produce " nowhere ", neither does
printf ("%.3s%-.6s", "noOoO", "whereEeEeEeE") produce " noOwhereE ".  You need
a field width bigger than the precision to get any padding.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (4 preceding siblings ...)
  2012-10-10 10:42 ` schwab@linux-m68k.org
@ 2012-10-10 10:58 ` lascania at gmail dot com
  2012-10-10 11:00 ` lascania at gmail dot com
                   ` (16 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10 10:58 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

--- Comment #4 from R N Alx <lascania at gmail dot com> 2012-10-10 10:57:31 UTC ---
Created attachment 6679
  --> http://sourceware.org/bugzilla/attachment.cgi?id=6679
.GIF picture with correct output conversion arguments printf() example

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (5 preceding siblings ...)
  2012-10-10 10:58 ` lascania at gmail dot com
@ 2012-10-10 11:00 ` lascania at gmail dot com
  2012-10-10 11:06 ` aj at suse dot de
                   ` (15 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10 11:00 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #5 from R N Alx <lascania at gmail dot com> 2012-10-10 10:59:57 UTC ---
Sir,

I'm sorry but you are mistaken.

Please see the image, to see confirmation.
http://sourceware.org/bugzilla/attachment.cgi?id=6679

Please modify the online manual to contain valid information !!!

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (6 preceding siblings ...)
  2012-10-10 11:00 ` lascania at gmail dot com
@ 2012-10-10 11:06 ` aj at suse dot de
  2012-10-10 11:16 ` lascania at gmail dot com
                   ` (14 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: aj at suse dot de @ 2012-10-10 11:06 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Jaeger <aj at suse dot de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |aj at suse dot de

--- Comment #6 from Andreas Jaeger <aj at suse dot de> 2012-10-10 11:06:32 UTC ---
Just a question: Shouldn't the manual say "field width" instead of precision?

This is an example of a field of with 3:
printf ("%3s",...)

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (7 preceding siblings ...)
  2012-10-10 11:06 ` aj at suse dot de
@ 2012-10-10 11:16 ` lascania at gmail dot com
  2012-10-10 11:59 ` schwab@linux-m68k.org
                   ` (13 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10 11:16 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

--- Comment #7 from R N Alx <lascania at gmail dot com> 2012-10-10 11:15:39 UTC ---
(In reply to comment #6)
> Just a question: Shouldn't the manual say "field width" instead of precision?
> 
> This is an example of a field of with 3:
> printf ("%3s",...)

Your example is wrong, because you must put a dot before three, .3, if you want
to printf() only the first three3 characters of a string !

The manual should say something like, "to output less than the width of a
string use the precision option .n to output only first n characters from a
string".

Regarding numbers, the manual should continue use precision.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (8 preceding siblings ...)
  2012-10-10 11:16 ` lascania at gmail dot com
@ 2012-10-10 11:59 ` schwab@linux-m68k.org
  2012-10-10 12:16 ` lascania at gmail dot com
                   ` (12 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-10 11:59 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Schwab <schwab@linux-m68k.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID

--- Comment #8 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-10 11:58:57 UTC ---
This example has nothing to do with field width or precision, it is about
alignment (which is useless without a field width).

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (9 preceding siblings ...)
  2012-10-10 11:59 ` schwab@linux-m68k.org
@ 2012-10-10 12:16 ` lascania at gmail dot com
  2012-10-10 12:33 ` schwab@linux-m68k.org
                   ` (11 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-10 12:16 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #9 from R N Alx <lascania at gmail dot com> 2012-10-10 12:15:26 UTC ---
Mr Schwab

You said,
printf ("%.3s%-.6s", "no", "where") does not produce " nowhere "

You said,
printf ("%.3s%-.6s", "noOoO", "whereEeEeEeE") does not produce " noOwhereE "

THEY BOTH PRODUCE, " nowhere " RESPECTIVELY " noOwhereE "



Are you able too see pictures on your computer, or are you still using an old
text-screen terminal ?



My bug is about
R N Alx 2012-10-10 10:28:12 UTC
http://sourceware.org/bugzilla/show_bug.cgi?id=14695#c2



If you do not understand, please let other people have a look at the images,
and decide on this subject !

Do no longer stamp my bug as RESOLVED INVALID !

Thank You Sir !

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (10 preceding siblings ...)
  2012-10-10 12:16 ` lascania at gmail dot com
@ 2012-10-10 12:33 ` schwab@linux-m68k.org
  2012-10-11 11:31 ` lascania at gmail dot com
                   ` (10 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-10 12:33 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Schwab <schwab@linux-m68k.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID

--- Comment #10 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-10 12:33:27 UTC ---
printf ("%.3s%-.6s", "no", "where") produces "nowhere" and printf ("%.3s%-.6s",
"noOoO", "whereEeEeEeE") produces "noOwhereE".

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (11 preceding siblings ...)
  2012-10-10 12:33 ` schwab@linux-m68k.org
@ 2012-10-11 11:31 ` lascania at gmail dot com
  2012-10-11 11:53 ` schwab@linux-m68k.org
                   ` (9 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-11 11:31 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #11 from R N Alx <lascania at gmail dot com> 2012-10-11 11:31:08 UTC ---
COMPARE
http://sourceware.org/bugzilla/show_bug.cgi?id=14695#c3
http://sourceware.org/bugzilla/show_bug.cgi?id=14695#c10

dude Schwab, just stay away ! keep distance, let somebody else look at the
issue, not you !

take a walk in nature, clean your mind !

STAY AWAY !!!!!!!!!

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (12 preceding siblings ...)
  2012-10-11 11:31 ` lascania at gmail dot com
@ 2012-10-11 11:53 ` schwab@linux-m68k.org
  2012-10-11 13:18 ` aj at suse dot de
                   ` (8 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-11 11:53 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Schwab <schwab@linux-m68k.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID

--- Comment #12 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-11 11:53:17 UTC ---
Stop reopening.  Nothing what you wrote is true.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (13 preceding siblings ...)
  2012-10-11 11:53 ` schwab@linux-m68k.org
@ 2012-10-11 13:18 ` aj at suse dot de
  2012-10-11 14:57 ` lascania at gmail dot com
                   ` (7 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: aj at suse dot de @ 2012-10-11 13:18 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

--- Comment #13 from Andreas Jaeger <aj at suse dot de> 2012-10-11 13:18:07 UTC ---
R NH Alx, we resolve conflicts in a friendly manner. Stop insulting Andreas
Schwab.

It's fine to disagree on a technical level - but then you have to accept that
Andreas is an expert in this area and disagrees with you.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (14 preceding siblings ...)
  2012-10-11 13:18 ` aj at suse dot de
@ 2012-10-11 14:57 ` lascania at gmail dot com
  2012-10-11 15:04 ` lascania at gmail dot com
                   ` (6 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-11 14:57 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

--- Comment #14 from R N Alx <lascania at gmail dot com> 2012-10-11 14:56:46 UTC ---
I do not care what flavour of expert is Andreas Schwab.

My physics teacher always tells me that the laws of physics are based only on
experiments and nobody with great authority can impose a law only because he
has greater authority !

In comment #3 and in comment #10, Andreas Schwab, contradicts himself, this
makes me believe that he has limited knowledge on the subject.

Question:
Can you folks view .GIF images on your computer screens ?

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (15 preceding siblings ...)
  2012-10-11 14:57 ` lascania at gmail dot com
@ 2012-10-11 15:04 ` lascania at gmail dot com
  2012-10-11 16:15 ` schwab@linux-m68k.org
                   ` (5 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-11 15:04 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #15 from R N Alx <lascania at gmail dot com> 2012-10-11 15:03:44 UTC ---
I want to output only 5characters from a 10character string

char str[] = "0123456789"

Which printf() call will do that job ?

I. printf("%5s", str)

or II. printf("%.5s", str)

Now lets see how big experts you are.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (16 preceding siblings ...)
  2012-10-11 15:04 ` lascania at gmail dot com
@ 2012-10-11 16:15 ` schwab@linux-m68k.org
  2012-10-11 16:51 ` ldv at altlinux dot org
                   ` (4 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-11 16:15 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Andreas Schwab <schwab@linux-m68k.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |INVALID

--- Comment #16 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-11 16:14:42 UTC ---
This is not the point of the example.  Read comment 8 again.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (17 preceding siblings ...)
  2012-10-11 16:15 ` schwab@linux-m68k.org
@ 2012-10-11 16:51 ` ldv at altlinux dot org
  2012-10-11 17:02 ` schwab@linux-m68k.org
                   ` (3 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: ldv at altlinux dot org @ 2012-10-11 16:51 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Dmitry V. Levin <ldv at altlinux dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ldv at altlinux dot org

--- Comment #17 from Dmitry V. Levin <ldv at altlinux dot org> 2012-10-11 16:51:13 UTC ---
(In reply to comment #8)
> This example has nothing to do with field width or precision, it is about
> alignment (which is useless without a field width).

The reporter seems to be confused by the fact that this example demonstrates
alignment while the text right before it talks about precision and there is no
example on precision.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (18 preceding siblings ...)
  2012-10-11 16:51 ` ldv at altlinux dot org
@ 2012-10-11 17:02 ` schwab@linux-m68k.org
  2012-10-12 12:16 ` lascania at gmail dot com
                   ` (2 subsequent siblings)
  22 siblings, 0 replies; 24+ messages in thread
From: schwab@linux-m68k.org @ 2012-10-11 17:02 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

--- Comment #18 from Andreas Schwab <schwab@linux-m68k.org> 2012-10-11 17:01:44 UTC ---
The last sentence before the example explicitly talks about the - flag.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (19 preceding siblings ...)
  2012-10-11 17:02 ` schwab@linux-m68k.org
@ 2012-10-12 12:16 ` lascania at gmail dot com
  2012-10-12 16:22 ` [Bug manual/14695] no example on printf precision " ldv at altlinux dot org
  2014-06-17  4:04 ` fweimer at redhat dot com
  22 siblings, 0 replies; 24+ messages in thread
From: lascania at gmail dot com @ 2012-10-12 12:16 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

R N Alx <lascania at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |

--- Comment #19 from R N Alx <lascania at gmail dot com> 2012-10-12 12:16:05 UTC ---
Alright !

Then take 2 minutes of your time and include an example on precision !
printf("%.5s", "0123456789")

produces:

‘01234’



Change the example about aligment from:
printf ("%3s%-6s", "no", "where");

change it to:
printf ("%10s(always)", "ON");
printf("\n");
printf ("%-10s(never)", "OFF");

produces:

‘        ON(always)’
newline
‘OFF       (never)’



And now you may stamp the bug as solved.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] no example on printf precision --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (20 preceding siblings ...)
  2012-10-12 12:16 ` lascania at gmail dot com
@ 2012-10-12 16:22 ` ldv at altlinux dot org
  2014-06-17  4:04 ` fweimer at redhat dot com
  22 siblings, 0 replies; 24+ messages in thread
From: ldv at altlinux dot org @ 2012-10-12 16:22 UTC (permalink / raw)
  To: glibc-bugs


http://sourceware.org/bugzilla/show_bug.cgi?id=14695

Dmitry V. Levin <ldv at altlinux dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |NEW
            Summary|Wrong printf("%3s"...)      |no example on printf
                   |Example --- manual          |precision --- manual
                   |subsection "12.12.6 Other   |subsection "12.12.6 Other
                   |Output Conversions"         |Output Conversions"
           Severity|minor                       |enhancement

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [Bug manual/14695] no example on printf precision --- manual subsection "12.12.6 Other Output Conversions"
  2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
                   ` (21 preceding siblings ...)
  2012-10-12 16:22 ` [Bug manual/14695] no example on printf precision " ldv at altlinux dot org
@ 2014-06-17  4:04 ` fweimer at redhat dot com
  22 siblings, 0 replies; 24+ messages in thread
From: fweimer at redhat dot com @ 2014-06-17  4:04 UTC (permalink / raw)
  To: glibc-bugs

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

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
              Flags|                            |security-

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


^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2014-06-17  4:04 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-10  9:39 [Bug manual/14695] New: Wrong printf("%3s"...) Example --- manual subsection "12.12.6 Other Output Conversions" lascania at gmail dot com
2012-10-10  9:43 ` [Bug manual/14695] " lascania at gmail dot com
2012-10-10  9:46 ` lascania at gmail dot com
2012-10-10 10:01 ` schwab@linux-m68k.org
2012-10-10 10:28 ` lascania at gmail dot com
2012-10-10 10:42 ` schwab@linux-m68k.org
2012-10-10 10:58 ` lascania at gmail dot com
2012-10-10 11:00 ` lascania at gmail dot com
2012-10-10 11:06 ` aj at suse dot de
2012-10-10 11:16 ` lascania at gmail dot com
2012-10-10 11:59 ` schwab@linux-m68k.org
2012-10-10 12:16 ` lascania at gmail dot com
2012-10-10 12:33 ` schwab@linux-m68k.org
2012-10-11 11:31 ` lascania at gmail dot com
2012-10-11 11:53 ` schwab@linux-m68k.org
2012-10-11 13:18 ` aj at suse dot de
2012-10-11 14:57 ` lascania at gmail dot com
2012-10-11 15:04 ` lascania at gmail dot com
2012-10-11 16:15 ` schwab@linux-m68k.org
2012-10-11 16:51 ` ldv at altlinux dot org
2012-10-11 17:02 ` schwab@linux-m68k.org
2012-10-12 12:16 ` lascania at gmail dot com
2012-10-12 16:22 ` [Bug manual/14695] no example on printf precision " ldv at altlinux dot org
2014-06-17  4:04 ` fweimer at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).