ports/misc/brltty/patches/patch-Programs_cmd_c

16 lines
577 B
Text
Raw Normal View History

2023-08-16 22:26:55 +00:00
Index: Programs/cmd.c
--- Programs/cmd.c.orig
+++ Programs/cmd.c
@@ -87,8 +87,9 @@ describeCommand (int command, char *buffer, int size)
candidate->name, number, candidate->description);
} else {
int offset;
- snprintf(buffer, size, "%s: %n%s",
- candidate->name, &offset, candidate->description);
+ offset = strlen(candidate->name) + 2;
+ snprintf(buffer, size, "%s: %s",
+ candidate->name, candidate->description);
if ((blk == 0) && (command & BRL_FLG_TOGGLE_MASK)) {
char *description = buffer + offset;