mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-03 22:05:06 -05:00
client: check for allocation errors in tab completition
This commit is contained in:
2
client.c
2
client.c
@@ -1167,7 +1167,7 @@ command_name_generator(const char *text, int state)
|
|||||||
|
|
||||||
while ((name = names[tab_complete_index][list_index++])) {
|
while ((name = names[tab_complete_index][list_index++])) {
|
||||||
if (strncmp(name, text, len) == 0) {
|
if (strncmp(name, text, len) == 0) {
|
||||||
return strdup(name);
|
return Strdup(name);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user