From 58044c3948d4e3f8cc2ad9fa57dc1507a654fb3b Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Fri, 30 Jun 2017 08:17:09 +0200 Subject: [PATCH] posix/btstack_link_key_db_fs_instance: only btstack_link_key_db_fs_instance is public --- platform/posix/btstack_link_key_db_fs.c | 8 ++++---- platform/posix/btstack_link_key_db_fs.h | 23 ----------------------- 2 files changed, 4 insertions(+), 27 deletions(-) diff --git a/platform/posix/btstack_link_key_db_fs.c b/platform/posix/btstack_link_key_db_fs.c index 017348509..0eaacd214 100644 --- a/platform/posix/btstack_link_key_db_fs.c +++ b/platform/posix/btstack_link_key_db_fs.c @@ -79,7 +79,7 @@ static char * bd_addr_to_dash_str(bd_addr_t addr){ } static char link_key_to_str_buffer[LINK_KEY_STR_LEN+1]; // 11223344556677889900112233445566\0 -char *link_key_to_str(link_key_t link_key){ +static char *link_key_to_str(link_key_t link_key){ char * p = link_key_to_str_buffer; int i; for (i = 0; i < LINK_KEY_LEN ; i++) { @@ -91,12 +91,12 @@ char *link_key_to_str(link_key_t link_key){ } static char link_key_type_to_str_buffer[2]; -char *link_key_type_to_str(link_key_type_t link_key){ +static char *link_key_type_to_str(link_key_type_t link_key){ snprintf(link_key_type_to_str_buffer, sizeof(link_key_type_to_str_buffer), "%d", link_key); return (char *) link_key_type_to_str_buffer; } -int sscanf_link_key(char * addr_string, link_key_t link_key){ +static int sscanf_link_key(char * addr_string, link_key_t link_key){ unsigned int buffer[LINK_KEY_LEN]; // reset result buffer @@ -190,7 +190,7 @@ static void delete_link_key(bd_addr_t bd_addr){ } } -const btstack_link_key_db_t btstack_link_key_db_fs = { +static const btstack_link_key_db_t btstack_link_key_db_fs = { &db_open, &db_set_local_bd_addr, &db_close, diff --git a/platform/posix/btstack_link_key_db_fs.h b/platform/posix/btstack_link_key_db_fs.h index e1f2cc335..2a73235f4 100644 --- a/platform/posix/btstack_link_key_db_fs.h +++ b/platform/posix/btstack_link_key_db_fs.h @@ -49,29 +49,6 @@ extern "C" { */ const btstack_link_key_db_t * btstack_link_key_db_fs_instance(void); -/** - * @brief Create human readable represenationt of link key - * @note uses fixed global buffer - * @return pointer to Bluetooth address string - */ -char * link_key_to_str(link_key_t link_key); - -/** - * @brief return string for link key type - * @note uses fixed global buffer - * @param link_key_type - * @return link_key_type as string - */ -char *link_key_type_to_str(link_key_type_t link_key_type); - -/** - * @brief Parse link key string - * @param addr_strings - * @param link_key buffer for result - * @return 1 on success - */ -int sscanf_link_key(char * addr_string, link_key_t link_key); - /* API_END */ #if defined __cplusplus