summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3dc5837)
raw | patch | inline | side by side (parent: 3dc5837)
author | Miroslav Lichvar <mlichvar@redhat.com> | |
Thu, 23 Feb 2017 14:42:55 +0000 (15:42 +0100) | ||
committer | Miroslav Lichvar <mlichvar@redhat.com> | |
Thu, 23 Feb 2017 16:48:58 +0000 (17:48 +0100) |
Since the IPAddr struct is declared with the packed attribute and
contains a 32-bit field, it needs to include a 16-bit padding in order
to be aligned to 32 bits.
contains a 32-bit field, it needs to include a 16-bit padding in order
to be aligned to 32 bits.
src/chrony.c | patch | blob | history |
diff --git a/src/chrony.c b/src/chrony.c
index 835c42538d1f3b46a41952368b380108744ca138..a4dd59f8131c10242e543fc4ebfcf2959ea5b15c 100644 (file)
--- a/src/chrony.c
+++ b/src/chrony.c
uint8_t ip6[16];
} addr;
uint16_t f_family;
+ uint16_t padding;
} tChrony_IPAddr;
typedef struct ATTRIB_PACKED {
tChrony_IPAddr addr;
- uint16_t
- dummy; /* FIXME: Strange dummy space. Needed on gcc 4.8.3/clang 3.4.1 on
- x86_64 */
int16_t f_poll; /* 2^f_poll = Time between polls (s) */
uint16_t f_stratum; /* Remote clock stratum */
uint16_t f_state; /* 0 = RPY_SD_ST_SYNC, 1 = RPY_SD_ST_UNREACH, 2 =
typedef struct ATTRIB_PACKED {
uint32_t f_ref_id;
tChrony_IPAddr addr;
- uint16_t
- dummy; /* FIXME: Strange dummy space. Needed on gcc 4.8.3/clang 3.4.1 on
- x86_64 */
uint32_t f_n_samples; /* Number of measurements done */
uint32_t f_n_runs; /* How many measurements to come */
uint32_t f_span_seconds; /* For how long we're measuring */
typedef struct ATTRIB_PACKED {
uint32_t f_ref_id;
tChrony_IPAddr addr;
- uint16_t
- dummy; /* FIXME: Strange dummy space. Needed on gcc 4.8.3/clang 3.4.1 on
- x86_64 */
uint16_t f_stratum;
uint16_t f_leap_status;
tTimeval f_ref_time;