MCPcopy Create free account
hub / github.com/ddnet/ddnet / ReplaceData

Method ReplaceData

src/engine/shared/datafile.cpp:753–761  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

751}
752
753void CDataFileReader::ReplaceData(int Index, char *pData, size_t Size)
754{
755 dbg_assert(m_pDataFile != nullptr, "File not open");
756 dbg_assert(Index >= 0 && Index < m_pDataFile->m_Header.m_NumRawData, "Index invalid: %d", Index);
757
758 free(m_pDataFile->m_ppDataPtrs[Index]);
759 m_pDataFile->m_ppDataPtrs[Index] = pData;
760 m_pDataFile->m_pDataSizes[Index] = Size;
761}
762
763void CDataFileReader::UnloadData(int Index)
764{

Callers 1

LoadMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected