]> git.sesse.net Git - vlc/commitdiff
HTTP interface: fix infinite loop
authorJean-Baptiste Kempf <jb@videolan.org>
Sun, 29 Sep 2013 20:47:08 +0000 (22:47 +0200)
committerJean-Baptiste Kempf <jb@videolan.org>
Sun, 29 Sep 2013 20:47:08 +0000 (22:47 +0200)
share/lua/intf/modules/httprequests.lua

index 33be631e3dc7a5216d01effe12b3a9059c2b6d19..444f89d6272434e8af40050ef8f0be39e139405e 100644 (file)
@@ -52,7 +52,6 @@ function strsplit(text, delimiter)
     end
     local i=1
     while 1 do
-        i=i+1
         local first, last = strfind(text, delimiter, pos)
         if first then -- found?
             tinsert(list,i, strsub(text, pos, first-1))
@@ -61,6 +60,7 @@ function strsplit(text, delimiter)
             tinsert(list,i, strsub(text, pos))
             break
         end
+        i = i+1
     end
     return list
 end