public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
From: Alejandro Colomar <colomar.6.4.3@gmail.com>
To: mtk.manpages@gmail.com
Cc: Alejandro Colomar <colomar.6.4.3@gmail.com>, linux-man@vger.kernel.org
Subject: [PATCH 1/3] strtol.3: EXAMPLES: Delimit output string using ""
Date: Wed, 28 Oct 2020 10:33:06 +0100	[thread overview]
Message-ID: <20201028093308.86310-2-colomar.6.4.3@gmail.com> (raw)
In-Reply-To: <20201028093308.86310-1-colomar.6.4.3@gmail.com>

Signed-off-by: Alejandro Colomar <colomar.6.4.3@gmail.com>
---
 man3/strtol.3 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/man3/strtol.3 b/man3/strtol.3
index 20b453330..0feb12dbb 100644
--- a/man3/strtol.3
+++ b/man3/strtol.3
@@ -236,7 +236,7 @@ strtol() returned 123
 strtol() returned 123
 .RB "$" " ./a.out 123abc"
 strtol() returned 123
-Further characters after number: abc
+Further characters after number: "abc"
 .RB "$" " ./a.out 123abc 55"
 strtol: Invalid argument
 .RB "$" " ./a.out \(aq\(aq"
@@ -289,7 +289,7 @@ main(int argc, char *argv[])
     printf("strtol() returned %ld\en", val);
 
     if (*endptr != \(aq\e0\(aq)        /* Not necessarily an error... */
-        printf("Further characters after number: %s\en", endptr);
+        printf("Further characters after number: \e"%s\e"\en", endptr);
 
     exit(EXIT_SUCCESS);
 }
-- 
2.28.0


  reply	other threads:[~2020-10-29  1:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-28  9:33 [PATCH 0/3] Improve strtol(3) example Alejandro Colomar
2020-10-28  9:33 ` Alejandro Colomar [this message]
2020-10-28  9:33 ` [PATCH 2/3] strtol.3: EXAMPLES: As the default base, use special value 0 Alejandro Colomar
2020-10-28  9:33 ` [PATCH 3/3] strtol.3: EXAMPLES: Simplify errno checking (no expected change in behavior) Alejandro Colomar
2020-10-28 10:13 ` [PATCH 0/3] Improve strtol(3) example Michael Kerrisk (man-pages)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201028093308.86310-2-colomar.6.4.3@gmail.com \
    --to=colomar.6.4.3@gmail.com \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox