parent
26fe6fdfa0
commit
b7184bbe91
@ -101,13 +101,21 @@ def ProbeCommentFormat(f):
|
|||||||
else:
|
else:
|
||||||
return None
|
return None
|
||||||
elif tmp == '<':
|
elif tmp == '<':
|
||||||
tmp = f.read(39)
|
tmp = f.read(1)
|
||||||
f.seek(0)
|
if tmp == '?':
|
||||||
if tmp == '?xml version="1.0" encoding="UTF-8"?><p':
|
tmp = f.read(38)
|
||||||
return 'Niconico'
|
f.seek(0)
|
||||||
elif tmp == '?xml version="1.0" encoding="UTF-8"?><i':
|
if tmp == 'xml version="1.0" encoding="UTF-8"?><p':
|
||||||
return 'Bilibili'
|
return 'Niconico'
|
||||||
|
elif tmp == 'xml version="1.0" encoding="UTF-8"?><i':
|
||||||
|
return 'Bilibili'
|
||||||
|
else:
|
||||||
|
return None
|
||||||
|
elif tmp == 'p':
|
||||||
|
f.seek(0)
|
||||||
|
return 'Niconico' # Himawari Douga, with the same file format as Niconico Douga
|
||||||
else:
|
else:
|
||||||
|
f.seek(0)
|
||||||
return None
|
return None
|
||||||
else:
|
else:
|
||||||
f.seek(0)
|
f.seek(0)
|
||||||
|
Loading…
Reference in New Issue
Block a user