浏览代码

Don't forget trailing '%'

fnord 10 年之前
父节点
当前提交
593b77064c
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      youtube_dl/compat.py

+ 3 - 0
youtube_dl/compat.py

@@ -98,6 +98,9 @@ except ImportError:
         append = res.append
         append = res.append
 
 
         for item in bits[1:]:
         for item in bits[1:]:
+            if item == '':
+                append(b'%')
+                continue
             try:
             try:
                 append(item[:2].decode('hex'))
                 append(item[:2].decode('hex'))
                 append(item[2:])
                 append(item[2:])