1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-11-30 13:01:23 +03:00

token: Added function to remove duplicates

Added a function to remove duplicates from lists.  This function is used
in a new provided function to append lists removing duplicates.

Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
Reviewed-by: Jakub Jelen <jjelen@redhat.com>
This commit is contained in:
Anderson Toshiyuki Sasaki
2019-06-28 22:35:38 +02:00
parent e5a64a3d6b
commit 548753b338
3 changed files with 278 additions and 2 deletions

View File

@@ -38,7 +38,11 @@ void ssh_tokens_free(struct ssh_tokens_st *tokens);
char *ssh_find_matching(const char *available_d,
const char *preferred_d);
char *ssh_find_all_matching(const char *available_d,
const char *preferred_d);
char *ssh_remove_duplicates(const char *list);
char *ssh_append_without_duplicates(const char *list,
const char *appended_list);
#endif /* TOKEN_H_ */