Skip to content

Commit

Permalink
use underscored names for c variables
Browse files Browse the repository at this point in the history
  • Loading branch information
toy committed Feb 29, 2020
1 parent f5d2779 commit 43ef7aa
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions blueutil.m
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ static inline bool is_caseabbr(const char* name, const char* str) {
return strncasecmp(name, str, length) == 0;
}

const char* hciErrorDescriptions[] = {
const char* hci_error_descriptions[] = {
[0x01] = "Unknown HCI Command",
[0x02] = "No Connection",
[0x03] = "Hardware Failure",
Expand Down Expand Up @@ -460,10 +460,10 @@ @implementation DevicePairDelegate
- (const char*)errorDescription {
if (
_errorCode >= 0 &&
(unsigned)_errorCode < sizeof(hciErrorDescriptions) / sizeof(hciErrorDescriptions[0]) &&
hciErrorDescriptions[_errorCode]
(unsigned)_errorCode < sizeof(hci_error_descriptions) / sizeof(hci_error_descriptions[0]) &&
hci_error_descriptions[_errorCode]
) {
return hciErrorDescriptions[_errorCode];
return hci_error_descriptions[_errorCode];
} else {
return "UNKNOWN ERROR";
}
Expand Down

0 comments on commit 43ef7aa

Please sign in to comment.