diff options
author | Felix Fietkau <nbd@openwrt.org> | 2009-10-26 04:52:07 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2009-10-26 04:52:07 +0000 |
commit | 64d9a00a9934cd06401f4b9ec2e14950a4423a87 (patch) | |
tree | 99f8a9f96407f1420e36a37f02a000346dc6ca81 /libs/nixio/src/binary.c | |
parent | 2181825db596a12d23f56fa8fbfebd94f99b13c4 (diff) |
nixio: store stats and other number information as integer, which works better when lua number support is downgraded from double to float
Diffstat (limited to 'libs/nixio/src/binary.c')
-rw-r--r-- | libs/nixio/src/binary.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/nixio/src/binary.c b/libs/nixio/src/binary.c index c2de38817..2c4162228 100644 --- a/libs/nixio/src/binary.c +++ b/libs/nixio/src/binary.c @@ -97,7 +97,7 @@ static const uint32_t nixio__crc32_tbl[] = { static int nixio_bin_crc32(lua_State *L) { size_t len; const char *buffer = luaL_checklstring(L, 1, &len); - uint32_t value = luaL_optnumber(L, 2, 0); + uint32_t value = luaL_optinteger(L, 2, 0); value = ~value; for (size_t i=0; i<len; i++) { |