MCPcopy Create free account
hub / github.com/GrapheneCt/NetStream / HistLog

Method HistLog

NetStream/source/tw_utils.cpp:135–167  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133}
134
135twutils::HistLog::HistLog()
136{
137 uint32_t i = 0;
138 char val[2];
139 char data[SCE_INI_FILE_PROCESSOR_KEY_BUFFER_SIZE];
140 Ini::InitParameter param;
141 Ini::MemAllocator alloc;
142 alloc.allocate = sce_paf_malloc;
143 alloc.deallocate = sce_paf_free;
144
145 param.workmemSize = SCE_KERNEL_4KiB;
146 param.unk_0x4 = SCE_KERNEL_4KiB;
147 param.allocator = &alloc;
148
149 m_ini = new Ini::IniFileProcessor();
150 m_ini->initialize(&param);
151 m_ini->open("savedata0:tw_hist_log.ini", "rw", 0);
152
153 i = m_ini->size();
154 if (i <= k_maxHistItems)
155 return;
156
157 i = i - k_maxHistItems;
158
159 while (i != 0)
160 {
161 m_ini->parse(data, val, sizeof(val));
162 m_ini->del(data);
163 i--;
164 }
165
166 m_ini->reset();
167}
168
169twutils::FavLog::FavLog()
170{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected