aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2013-04-21 20:17:10 -0700
committerAlon Zakai <alonzakai@gmail.com>2013-04-29 13:01:59 -0700
commitf2338f77c9bc16a8565243b242217ad95c23e375 (patch)
tree6df5f5cdea4047e03e1d04f8bbaefc95d51630ac
parent9b8e4488d77bffe68c3d7fd0df5f5f807331a3d6 (diff)
do not hope for 64-bit alignment with doubles in DOUBLE_MODE 0 since we will read only 32 bits anyhow
-rw-r--r--src/parseTools.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/parseTools.js b/src/parseTools.js
index 77ab979d..192b58ef 100644
--- a/src/parseTools.js
+++ b/src/parseTools.js
@@ -1130,6 +1130,7 @@ function makeGetValue(ptr, pos, type, noNeedFirst, unsigned, ignore, align, noSa
if (USE_TYPED_ARRAYS == 2 && align) {
// Alignment is important here. May need to split this up
var bytes = Runtime.getNativeTypeSize(type);
+ if (DOUBLE_MODE == 0 && type == 'double') bytes = 4; // we will really only read 4 bytes here
if (bytes > align) {
var ret = '(';
if (isIntImplemented(type)) {