Merge pull request #1452 from Uristqwerty/master

Infinite loop fix for splitting on null
This commit is contained in:
Albert Iordache
2012-07-07 20:24:39 -07:00
+3
View File
@@ -1753,6 +1753,9 @@ proc/oview_or_orange(distance = world.view , center = usr , type)
return
/proc/stringsplit(txt, character)
if(length(character) < 1) //Do not infinite loop when splitting on "" or null
return list(txt)
var/cur_text = txt
var/last_found = 1
var/found_char = findtext(cur_text,character)