mirror of
https://github.com/rehlds/rehlds.git
synced 2024-12-29 08:05:50 +03:00
HLTV: Fix typo.
This commit is contained in:
parent
7432df957c
commit
18f75dadf4
@ -363,10 +363,10 @@ bool DemoFile::LoadDemo(char *demoname)
|
||||
m_FileSystem->Read(&m_EntryNumber, sizeof(int), m_FileHandle);
|
||||
m_CurrentEntry = 0;
|
||||
|
||||
if (m_EntryNumber > 0 && m_EntryNumber <= 1024)
|
||||
if (m_EntryNumber > 0 && m_EntryNumber <= MAX_DEMO_ENTRY)
|
||||
{
|
||||
m_Entries = (demoentry_t *)Mem_ZeroMalloc(m_EntryNumber * MAX_DEMO_ENTRY);
|
||||
m_FileSystem->Read(m_Entries, m_EntryNumber * MAX_DEMO_ENTRY, m_FileHandle);
|
||||
m_Entries = (demoentry_t *)Mem_ZeroMalloc(sizeof(demoentry_t) * m_EntryNumber);
|
||||
m_FileSystem->Read(m_Entries, sizeof(demoentry_t) * m_EntryNumber, m_FileHandle);
|
||||
m_FileSystem->Seek(m_FileHandle, m_Entries[m_CurrentEntry].nOffset, FILESYSTEM_SEEK_HEAD);
|
||||
}
|
||||
else
|
||||
|
@ -39,7 +39,7 @@
|
||||
#include "vmodes.h"
|
||||
#include "cdll_int.h"
|
||||
|
||||
const int MAX_DEMO_ENTRY = 92;
|
||||
const int MAX_DEMO_ENTRY = 1024;
|
||||
|
||||
const int DEMO_PROTOCOL = 5;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user