Skip to content

Commit

Permalink
Fix crash if metarule not found
Browse files Browse the repository at this point in the history
  • Loading branch information
Ekdohibs committed Jan 4, 2014
1 parent ae557d1 commit b3f3692
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion mesecons/util.lua
Expand Up @@ -91,7 +91,13 @@ end
function mesecon:rule2meta(findrule, allrules)
local index = mesecon:rule2metaindex(findrule, allrules)
if index == nil then return allrules end
if index == nil then
if allrules[1].x then
return allrules
else
return {}
end
end
return allrules[index]
end
Expand Down

0 comments on commit b3f3692

Please sign in to comment.