diff options
| author | Alejandro Colomar <alx@kernel.org> | 2023-05-03 00:48:14 +0200 |
|---|---|---|
| committer | Alejandro Colomar <alx@kernel.org> | 2023-05-03 00:48:22 +0200 |
| commit | fe5dba139dc089eae4061fdc17f087e71f48b198 (patch) | |
| tree | 54af56b1b0138bde9a21e99372ab68ce4d64564a /man3/strftime.3 | |
| parent | 5a0d9ed151e6449d978fabdd654cacc17b20a235 (diff) | |
| download | man-pages-fe5dba139dc089eae4061fdc17f087e71f48b198.tar.gz | |
man*/, man.ignore.grep: srcfix; warn about blank lines
- Use the dummy character to avoid warnings in examples.
- Re-enable the warning.
Suggested-by: "G. Branden Robinson" <g.branden.robinson@gmail.com>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
Diffstat (limited to 'man3/strftime.3')
| -rw-r--r-- | man3/strftime.3 | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/man3/strftime.3 b/man3/strftime.3 index 38bb8814bd..6d77faf14c 100644 --- a/man3/strftime.3 +++ b/man3/strftime.3 @@ -745,26 +745,26 @@ Result string is " 11" #include <stdio.h> #include <stdlib.h> #include <time.h> - +\& int main(int argc, char *argv[]) { char outstr[200]; time_t t; struct tm *tmp; - +\& t = time(NULL); tmp = localtime(&t); if (tmp == NULL) { perror("localtime"); exit(EXIT_FAILURE); } - +\& if (strftime(outstr, sizeof(outstr), argv[1], tmp) == 0) { fprintf(stderr, "strftime returned 0"); exit(EXIT_FAILURE); } - +\& printf("Result string is \e"%s\e"\en", outstr); exit(EXIT_SUCCESS); } |
