summaryrefslogtreecommitdiff
path: root/src/scanopt.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/scanopt.c')
-rw-r--r--src/scanopt.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/scanopt.c b/src/scanopt.c
index 7745c11..0b6d7d1 100644
--- a/src/scanopt.c
+++ b/src/scanopt.c
@@ -366,14 +366,8 @@ int scanopt_usage (scanopt_t *scanner, FILE *fp, const char *usage)
}
desccol = maxlen[0] + indent * 2;
-#define PRINT_SPACES(fp,n)\
- do{\
- int _n;\
- _n=(n);\
- while(_n-- > 0)\
- fputc(' ',(fp));\
- }while(0)
-
+#define PRINT_SPACES(fp,n) \
+ fprintf((fp), "%*s", (n), "")
/* Second pass (same as above loop), this time we print. */
/* Sloppy hack: We iterate twice. The first time we print short and long options.