Add Peer ID for Xfplay torrent client
This is based on the following resources, http://www.xfplay.com/history.html https://down.xfplay.com/xfplay9.994.exe https://down.xfplay.com/xfplay9.992.exe https://down.xfplay.com/xfplay9.991.exe https://down.xfplay.com/xfplay9.99.exe http://q.xfplay.com/
This commit is contained in:
parent
4f9d9ad92b
commit
e970d7e546
|
@ -30,6 +30,12 @@ int main(void)
|
|||
TEST_CLIENT("-BT791\0-", "BitTorrent 7.9.1");
|
||||
TEST_CLIENT("-BT791B-", "BitTorrent 7.9.1 (Beta)");
|
||||
|
||||
/* Xfplay 9.9.92 to 9.9.94 uses "-XF9992-" */
|
||||
TEST_CLIENT("-XF9992-", "Xfplay 9.9.92");
|
||||
|
||||
/* Older Xfplay versions have three digit version number */
|
||||
TEST_CLIENT("-XF9990-", "Xfplay 9.9.9");
|
||||
|
||||
/* gobbledygook */
|
||||
TEST_CLIENT("-IIO\x10\x2D\x04-", "-IIO%10-%04-");
|
||||
TEST_CLIENT("-I\05O\x08\x03\x01-", "-I%05O%08%03%01-");
|
||||
|
|
|
@ -587,6 +587,17 @@ char* tr_clientForId(char* buf, size_t buflen, void const* id_in)
|
|||
{
|
||||
tr_snprintf(buf, buflen, "MediaGet %d.%02d", charint(id[3]), charint(id[4]));
|
||||
}
|
||||
else if (strncmp(chid + 1, "XF", 2) == 0)
|
||||
{
|
||||
if (chid[6] == '0')
|
||||
{
|
||||
three_digits(buf, buflen, "Xfplay", id + 3);
|
||||
}
|
||||
else
|
||||
{
|
||||
tr_snprintf(buf, buflen, "Xfplay %d.%d.%d", strint(id + 3, 1), strint(id + 4, 1), strint(id + 5, 2));
|
||||
}
|
||||
}
|
||||
|
||||
if (*buf)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue