Add statics --nobuild

This commit is contained in:
Willy-JL
2023-10-19 11:21:57 +01:00
parent b35221f0a3
commit f76f9008eb
4 changed files with 7 additions and 7 deletions

View File

@@ -104,7 +104,7 @@ static Attack attacks[] = {
#define ATTACKS_COUNT ((signed)COUNT_OF(attacks))
uint16_t delays[] = {20, 50, 100, 200};
static uint16_t delays[] = {20, 50, 100, 200};
typedef struct {
Ctx ctx;

View File

@@ -16,7 +16,7 @@ static const char* type_names[ContinuityTypeCount] = {
[ContinuityTypeNearbyInfo] = "Nearby Info",
[ContinuityTypeCustomCrash] = "Custom Packet",
};
const char* continuity_get_name(const ProtocolCfg* _cfg) {
static const char* continuity_get_name(const ProtocolCfg* _cfg) {
const ContinuityCfg* cfg = &_cfg->continuity;
return type_names[cfg->type];
}
@@ -33,7 +33,7 @@ static uint8_t packet_sizes[ContinuityTypeCount] = {
[ContinuityTypeCustomCrash] = HEADER_LEN + 11,
};
void continuity_make_packet(uint8_t* _size, uint8_t** _packet, const ProtocolCfg* _cfg) {
static void continuity_make_packet(uint8_t* _size, uint8_t** _packet, const ProtocolCfg* _cfg) {
const ContinuityCfg* cfg = _cfg ? &_cfg->continuity : NULL;
ContinuityType type;

View File

@@ -4,13 +4,13 @@
// Hacked together by @Willy-JL and @Spooks4576
// Documentation at https://developers.google.com/nearby/fast-pair/specifications/introduction
const char* fastpair_get_name(const ProtocolCfg* _cfg) {
static const char* fastpair_get_name(const ProtocolCfg* _cfg) {
const FastpairCfg* cfg = &_cfg->fastpair;
UNUSED(cfg);
return "FastPair";
}
void fastpair_make_packet(uint8_t* _size, uint8_t** _packet, const ProtocolCfg* _cfg) {
static void fastpair_make_packet(uint8_t* _size, uint8_t** _packet, const ProtocolCfg* _cfg) {
const FastpairCfg* cfg = _cfg ? &_cfg->fastpair : NULL;
uint32_t model_id;

View File

@@ -4,13 +4,13 @@
// Hacked together by @Willy-JL and @Spooks4576
// Documentation at https://learn.microsoft.com/en-us/windows-hardware/design/component-guidelines/bluetooth-swift-pair
const char* swiftpair_get_name(const ProtocolCfg* _cfg) {
static const char* swiftpair_get_name(const ProtocolCfg* _cfg) {
const SwiftpairCfg* cfg = &_cfg->swiftpair;
UNUSED(cfg);
return "SwiftPair";
}
void swiftpair_make_packet(uint8_t* _size, uint8_t** _packet, const ProtocolCfg* _cfg) {
static void swiftpair_make_packet(uint8_t* _size, uint8_t** _packet, const ProtocolCfg* _cfg) {
const SwiftpairCfg* cfg = _cfg ? &_cfg->swiftpair : NULL;
const char* display_name;