Fix several calls that had wraparound hazards.

llGetSubString("abc", 3, -1) gives "abc"; llList2List(L, 1, -1) gives L when L has length 1. In general, llGetSubString or llList2List return the whole thing when the starting index is grater than the last element in the list.

There were a number of spots with that hazard, so fix all we found.
This commit is contained in:
Sei Lisa 2017-11-01 00:36:12 +01:00 committed by Sei-Lisa
parent aa9cba13a5
commit bf8f10bfe6
15 changed files with 39 additions and 39 deletions

View file

@ -269,7 +269,7 @@ default
{
list datalist = llParseString2List(data, [" "], []);
string command = llList2String(datalist, 0);
data = llStringTrim(llDumpList2String(llList2List(datalist, 1, -1), " "), STRING_TRIM);
data = llStringTrim(llDumpList2String(llList2List(datalist, 1, 99999), " "), STRING_TRIM);
list commands = ["PLAY", "WAIT", "SAY", "WHISPER", "SOUND", "LOOP"];
if (command == "DEBUG")
{