summaryrefslogtreecommitdiff
path: root/time.c
diff options
context:
space:
mode:
authornormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-02-24 11:10:11 +0000
committernormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-02-24 11:10:11 +0000
commit131e4bec04f40f3dd020ce7fd8467c6a58105baa (patch)
tree547e5666f873bfb217ac57d8057982d1a39e8538 /time.c
parentfa7b849f946c37422d27ce601582a7aa24eed0e3 (diff)
time: only use packed struct on x86*
* configure.in: define PACKED_STRUCT_UNALIGNED for x86* * timev.h (struct vtm): use PACKED_STRUCT_UNALIGNED * time.c (struct time_object): ditto [Bug #9558] non-x86 cannot safely access unaligned addresses git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45165 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'time.c')
-rw-r--r--time.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/time.c b/time.c
index 208d5c067b..acd589a8fc 100644
--- a/time.c
+++ b/time.c
@@ -1745,7 +1745,7 @@ struct time_object {
struct vtm vtm;
uint8_t gmt:3; /* 0:utc 1:localtime 2:fixoff 3:init */
uint8_t tm_got:1;
-} PACKED_STRUCT;
+} PACKED_STRUCT_UNALIGNED;
#define GetTimeval(obj, tobj) ((tobj) = get_timeval(obj))
#define GetNewTimeval(obj, tobj) ((tobj) = get_new_timeval(obj))