summaryrefslogtreecommitdiffhomepage
path: root/src/pack.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/pack.c')
-rw-r--r--src/pack.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pack.c b/src/pack.c
index e28c0ca73..7d68dd338 100644
--- a/src/pack.c
+++ b/src/pack.c
@@ -193,9 +193,9 @@ pack_double(mrb_state *mrb, mrb_value o, mrb_value str, mrb_int sidx, unsigned i
{
int i;
double d;
+ uint8_t *buffer = (uint8_t *)&d;
str = str_len_ensure(mrb, str, sidx + 8);
d = mrb_float(o);
- uint8_t *buffer = (uint8_t *)&d;
#ifdef MRB_ENDIAN_BIG
#error unsupported