[vlc-commits] HTTP interface: fix infinite loop

Jean-Baptiste Kempf git at videolan.org
Sun Sep 29 22:48:34 CEST 2013


vlc/vlc-2.1 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sun Sep 29 22:47:08 2013 +0200| [c109c1950ae65c9f6ec3eef48cc900f4e866e3b5] | committer: Jean-Baptiste Kempf

HTTP interface: fix infinite loop

(cherry picked from commit 5f58853765d3891c9fe7c12b13525ab071eac1eb)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.1.git/?a=commit;h=c109c1950ae65c9f6ec3eef48cc900f4e866e3b5
---

 share/lua/intf/modules/httprequests.lua |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/share/lua/intf/modules/httprequests.lua b/share/lua/intf/modules/httprequests.lua
index 33be631..444f89d 100644
--- a/share/lua/intf/modules/httprequests.lua
+++ b/share/lua/intf/modules/httprequests.lua
@@ -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



More information about the vlc-commits mailing list