aboutsummaryrefslogtreecommitdiffstats
path: root/epan/wslua/wslua_tvb.c
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2014-10-12 22:27:54 +0200
committerStig Bjørlykke <stig@bjorlykke.org>2014-10-13 19:06:40 +0000
commitb653564fe21c84482d99586b437be1ffcb35459a (patch)
tree4cc26824d0f23c777a64d267988bb2c1440a66f0 /epan/wslua/wslua_tvb.c
parent9ce5ca581d30074c2c02eca0f51dbe840bf9411b (diff)
Lua: luaL_checkstring does not return NULL
Removed all checks for NULL strings to cleanup the code. Change-Id: Ia890cd9b206296f586e85214f07765f14984580b Reviewed-on: https://code.wireshark.org/review/4632 Tested-by: Stig Bjørlykke <stig@bjorlykke.org> Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Diffstat (limited to 'epan/wslua/wslua_tvb.c')
-rw-r--r--epan/wslua/wslua_tvb.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/epan/wslua/wslua_tvb.c b/epan/wslua/wslua_tvb.c
index b78814c441..2e129ade98 100644
--- a/epan/wslua/wslua_tvb.c
+++ b/epan/wslua/wslua_tvb.c
@@ -51,11 +51,6 @@ WSLUA_CONSTRUCTOR ByteArray_new(lua_State* L) { /* Creates a `ByteArray` object.
if (lua_gettop(L) >= 1) {
s = luaL_checklstring(L,WSLUA_OPTARG_ByteArray_new_HEXBYTES,&len);
- if (!s) {
- WSLUA_OPTARG_ERROR(ByteArray_new,HEXBYTES,"must be a string");
- return 0;
- }
-
if (lua_gettop(L) >= 2) {
if (lua_type(L,2) == LUA_TBOOLEAN && lua_toboolean(L,2)) {
ishex = FALSE;