Mercurial > hg > th-libs
comparison th_args.c @ 750:56594b498180
Adjust short option cosmetics in help.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Fri, 30 Dec 2022 09:12:47 +0200 |
parents | 31bc1ed07cf5 |
children |
comparison
equal
deleted
inserted
replaced
749:feadd3678d2e | 750:56594b498180 |
---|---|
269 snprintf(fmtBuf, sizeof(fmtBuf), " -%c <%s>", | 269 snprintf(fmtBuf, sizeof(fmtBuf), " -%c <%s>", |
270 opt->o_short, arg); | 270 opt->o_short, arg); |
271 } | 271 } |
272 else | 272 else |
273 { | 273 { |
274 snprintf(fmtBuf, sizeof(fmtBuf), " -%c,", | 274 snprintf(fmtBuf, sizeof(fmtBuf), " -%c%s", |
275 opt->o_short); | 275 opt->o_short, |
276 hasLongOpt ? "," : ""); | |
276 } | 277 } |
277 | 278 |
278 *optWidth = strlen(fmtBuf); | 279 *optWidth = strlen(fmtBuf); |
279 if (doPrint) | 280 if (doPrint) |
280 padWidth = hasLongOpt ? 2 : maxOptWidth - *optWidth; | 281 padWidth = hasLongOpt ? 2 : maxOptWidth - *optWidth; |