diff options
author | Alexander Yakushev <yakushev.alex@gmail.com> | 2010-11-30 07:32:37 +0200 |
---|---|---|
committer | Alexander Yakushev <yakushev.alex@gmail.com> | 2010-11-30 07:32:37 +0200 |
commit | 0e0b19c905d58f6795a57f8042a958a76dec7f60 (patch) | |
tree | cd3b03ed9bdf39feb0a26be536952ff1faf6fbd9 | |
parent | 7e9c7310ed8311d782216db211b359148af9d41c (diff) | |
download | awesompd-0e0b19c905d58f6795a57f8042a958a76dec7f60.tar.gz awesompd-0e0b19c905d58f6795a57f8042a958a76dec7f60.tar.bz2 |
Added a gag to prevent crashes on parsing errors
-rw-r--r-- | utf8.lua | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -100,6 +100,10 @@ end -- instead of bytes function utf8sub (s, i, j) j = j or -1 + + if i == nil then + return "" + end local pos = 1 local bytes = string.len(s) |