gamepack-manager: more reliable extra-urls.txt parsing
[xonotic/netradiant.git] / gamepack-manager
index 232c75962dc9ad21a60a937e24cad02c8bc7cbf4..efcb751f94a7056681739ce62e8f2223c339fdea 100755 (executable)
@@ -294,11 +294,12 @@ downloadExtraUrls ()
 {
        if [ -f 'extra-urls.txt' ]
        then
-               while IFS='     ' read -r extra_file extra_url
+               local line
+               while read line
                do
-                       (
-                               ${WGET} -O "${extra_file}" "${extra_url}"
-                       ) </dev/null
+                       local extra_file="$(echo "${line}" | cut -f1 -d$'\t')"
+                       local extra_url="$(echo "${line}" | cut -f2 -d$'\t')"
+                       ${WGET} -O "${extra_file}" "${extra_url}" < /dev/null
                done < 'extra-urls.txt'
        fi
 }