mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Don't try to load ddnet-ranks.json while fetcher is downloading it anyway
This commit is contained in:
parent
a20db6ec56
commit
bff1c12b83
|
@ -588,7 +588,6 @@ void CServerBrowser::Refresh(int Type)
|
|||
else if(Type == IServerBrowser::TYPE_DDNET)
|
||||
{
|
||||
LoadDDNetServers();
|
||||
LoadDDNetRanks();
|
||||
|
||||
// remove unknown elements of exclude list
|
||||
DDNetCountryFilterClean();
|
||||
|
@ -1013,6 +1012,12 @@ void CServerBrowser::LoadDDNetRanks()
|
|||
return;
|
||||
|
||||
const int Length = io_length(File);
|
||||
if(Length <= 0)
|
||||
{
|
||||
io_close(File);
|
||||
return;
|
||||
}
|
||||
|
||||
char *pBuf = (char *)mem_alloc(Length, 1);
|
||||
pBuf[0] = '\0';
|
||||
|
||||
|
|
Loading…
Reference in a new issue