From e18fe2050ffa7878c94e6281ccd770ba1d55e5a3 Mon Sep 17 00:00:00 2001 From: YAMAMOTO Takashi Date: Tue, 10 Nov 2020 22:43:46 +0900 Subject: [PATCH] wireless/bluetooth/btsak/btsak_gatt.c: Appease nxstyle --- wireless/bluetooth/btsak/btsak_gatt.c | 32 +++++++++++++++++---------- 1 file changed, 20 insertions(+), 12 deletions(-) diff --git a/wireless/bluetooth/btsak/btsak_gatt.c b/wireless/bluetooth/btsak/btsak_gatt.c index 2ccbd4175..136b8bf87 100644 --- a/wireless/bluetooth/btsak/btsak_gatt.c +++ b/wireless/bluetooth/btsak/btsak_gatt.c @@ -54,11 +54,11 @@ #include "btsak.h" /**************************************************************************** - * Private data + * Private Data ****************************************************************************/ /**************************************************************************** - * Private functions + * Private Functions ****************************************************************************/ /**************************************************************************** @@ -92,7 +92,8 @@ static void btsak_cmd_discover_common(FAR struct btsak_s *btsak, if (argc < argndx) { fprintf(stderr, - "ERROR: Invalid number of arguments. Found %d expected at least %u\n", + "ERROR: Invalid number of arguments. " + "Found %d expected at least %u\n", argc - 1, argndx - 1); btsak_gatt_showusage(btsak->progname, argv[0], EXIT_FAILURE); } @@ -154,7 +155,8 @@ static void btsak_cmd_discover_common(FAR struct btsak_s *btsak, sockfd = btsak_socket(btsak); if (sockfd >= 0) { - ret = ioctl(sockfd, SIOCBTDISCOVER, (unsigned long)((uintptr_t)&btreq)); + ret = ioctl(sockfd, SIOCBTDISCOVER, + (unsigned long)((uintptr_t)&btreq)); if (ret < 0) { fprintf(stderr, "ERROR: ioctl(SIOCBTDISCOVER) failed: %d\n", @@ -264,7 +266,8 @@ static void btsak_cmd_read_common(FAR struct btsak_s *btsak, int argc, if (argc < 4 || argc > 5) { fprintf(stderr, - "ERROR: Invalid number of arguments. Found %d expected 3 or 4\n", + "ERROR: Invalid number of arguments. " + "Found %d expected 3 or 4\n", argc - 1); btsak_gatt_showusage(btsak->progname, argv[0], EXIT_FAILURE); } @@ -388,7 +391,8 @@ void btsak_cmd_gatt_exchange_mtu(FAR struct btsak_s *btsak, int argc, sockfd = btsak_socket(btsak); if (sockfd >= 0) { - ret = ioctl(sockfd, SIOCBTEXCHANGE, (unsigned long)((uintptr_t)&btreq)); + ret = ioctl(sockfd, SIOCBTEXCHANGE, + (unsigned long)((uintptr_t)&btreq)); if (ret < 0) { fprintf(stderr, "ERROR: ioctl(SIOCBTEXCHANGE) failed: %d\n", @@ -412,7 +416,8 @@ void btsak_cmd_gatt_exchange_mtu(FAR struct btsak_s *btsak, int argc, * ****************************************************************************/ -void btsak_cmd_discover(FAR struct btsak_s *btsak, int argc, FAR char *argv[]) +void btsak_cmd_discover(FAR struct btsak_s *btsak, int argc, + FAR char *argv[]) { btsak_cmd_discover_common(btsak, argc, argv, GATT_DISCOVER); } @@ -468,7 +473,8 @@ void btsak_cmd_gatt_read(FAR struct btsak_s *btsak, int argc, * Name: btsak_cmd_gatt_read_multiple * * Description: - * gatt [-h] read-multiple [-h] public|private [ []..] + * gatt [-h] read-multiple [-h] public|private + * [ []..] * ****************************************************************************/ @@ -483,7 +489,8 @@ void btsak_cmd_gatt_read_multiple(FAR struct btsak_s *btsak, int argc, if (argc < 4) { fprintf(stderr, - "ERROR: Invalid number of arguments. Found %d expected at least 3\n", + "ERROR: Invalid number of arguments. " + "Found %d expected at least 3\n", argc - 1); btsak_gatt_showusage(btsak->progname, argv[0], EXIT_FAILURE); } @@ -495,7 +502,8 @@ void btsak_cmd_gatt_read_multiple(FAR struct btsak_s *btsak, int argc, * Name: btsak_cmd_gatt_write * * Description: - * gatt [-h] write [-h] [-h] public|private [ []..] + * gatt [-h] write [-h] [-h] public|private + * [ []..] * ****************************************************************************/ @@ -515,7 +523,8 @@ void btsak_cmd_gatt_write(FAR struct btsak_s *btsak, int argc, if (argc < 5) { fprintf(stderr, - "ERROR: Invalid number of arguments. Found %d expected at least 4\n", + "ERROR: Invalid number of arguments. " + "Found %d expected at least 4\n", argc - 1); btsak_gatt_showusage(btsak->progname, argv[0], EXIT_FAILURE); } @@ -586,7 +595,6 @@ void btsak_cmd_connect(FAR struct btsak_s *btsak, int argc, btsak_cmd_connect_common(btsak, argc, argv, SIOCBTCONNECT); } - /**************************************************************************** * Name: btsak_cmd_gatt_connect *