MCPcopy Create free account
hub / github.com/defold/defold / GetSystemInfo

Function GetSystemInfo

engine/dlib/src/dlib/sys_linux.cpp:197–215  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

195 }
196
197 void GetSystemInfo(SystemInfo* info)
198 {
199 memset(info, 0, sizeof(*info));
200 struct utsname uts;
201 uname(&uts);
202
203 dmStrlCpy(info->m_SystemName, "Linux", sizeof(info->m_SystemName));
204 dmStrlCpy(info->m_SystemVersion, uts.release, sizeof(info->m_SystemVersion));
205
206 const char* default_lang = "en_US";
207 const char* lang = getenv("LANG");
208 if (!lang)
209 {
210 dmLogWarning("Variable LANG not set");
211 lang = default_lang;
212 }
213 FillLanguageTerritory(lang, info);
214 FillTimeZone(info);
215 }
216
217 void GetSecureInfo(SystemInfo* info)
218 {

Callers

nothing calls this directly

Calls 4

dmStrlCpyFunction · 0.85
getenvFunction · 0.85
FillLanguageTerritoryFunction · 0.85
FillTimeZoneFunction · 0.70

Tested by

no test coverage detected