diff options
author | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2014-05-25 00:08:10 -0700 |
---|---|---|
committer | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2014-05-25 00:08:10 -0700 |
commit | 2bb31556caad644db0ce6d1c7dd55fcbca174e0e (patch) | |
tree | 4646eee740f5c66bbad9cffdd85bcdc35f0ab8eb /lcrypt/lcrypt_bits.c | |
parent | 9f909885184c48e3d9a5ef625b20ff61079341f5 (diff) |
Fixing a few warnings and errors.
Diffstat (limited to 'lcrypt/lcrypt_bits.c')
-rw-r--r-- | lcrypt/lcrypt_bits.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lcrypt/lcrypt_bits.c b/lcrypt/lcrypt_bits.c index 0ea7851..9712933 100644 --- a/lcrypt/lcrypt_bits.c +++ b/lcrypt/lcrypt_bits.c @@ -126,7 +126,7 @@ static int lcrypt_bget(lua_State *L) else if(type == B_STR) { int len = (bits + 7) / 8; - uint8_t data[len]; + uint8_t * data = (uint8_t *)alloca(len); memset(data, 0, len); copy_bits(data, 0, in, offset, bits); lua_pushlstring(L, (char*)data, len); @@ -176,7 +176,7 @@ static int lcrypt_bput(lua_State *L) len += bits; } len = (len + 7) / 8; - uint8_t ret[len]; + uint8_t * ret = (uint8_t *)alloca(len); memset(ret, 0, len); for(i = 1; i <= argc; i += 3) |