From a8cdee9ee6dfce6a89d03acc1fbef859f3aa846c Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Thu, 24 Mar 2022 13:38:31 +0100 Subject: Rename custom __packed__ attribute to __o3000_packed__ Note: It is generally a bad idea to create identifier that start with an underscore [1]. In macOS the identifier __packed__ is already defined, because the packed attribute is written as __attribute__ ((__packed__)), which causes the code to fail to compile. To solve the problem this commit replaces __packed__ with __o3000_packed__. [1]: https://en.cppreference.com/w/c/language/identifier#Reserved_identifiers --- image_header.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'image_header.h') diff --git a/image_header.h b/image_header.h index b4eb2fc..13fa7e0 100644 --- a/image_header.h +++ b/image_header.h @@ -151,7 +151,7 @@ struct img_header_t { uint16_t fov_y_end; ///< end y-cooredinate of current field of view (2 bytes) uint8_t padding[452]; ///< padding bytes to fill header (452 bytes) -} __packed__; +} __o3000_packed__; #endif // _IMAGE_HEADER_H -- cgit v1.2.1