mirror of
https://github.com/greatscottgadgets/hackrf.git
synced 2026-03-11 09:54:43 +01:00
Add 'nonstring' attribute to firmware_info magic field.
Fixes compiler warnings such as:
firmware_info.c:49:18: warning: initializer-string for array of 'char'
truncates NUL terminator but destination lacks 'nonstring' attribute (9
chars into 8 available) [-Wunterminated-string-initialization]
49 | .magic = "HACKRFFW",
| ^~~~~~~~~~
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
#include <stdint.h>
|
||||
|
||||
struct firmware_info_t {
|
||||
char magic[8];
|
||||
__attribute__((nonstring)) char magic[8];
|
||||
uint16_t struct_version;
|
||||
uint16_t dfu_mode;
|
||||
uint32_t supported_platform;
|
||||
|
||||
Reference in New Issue
Block a user