mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-30 09:33:39 +01:00
Refactored read methods
This commit is contained in:
+2
-2
@@ -10,9 +10,9 @@ static double getGhz(const char* policyFile, const char* cpuFile)
|
||||
FFstrbuf content;
|
||||
ffStrbufInit(&content);
|
||||
|
||||
ffGetFileContent(policyFile, &content);
|
||||
ffGetFileBuffer(policyFile, &content);
|
||||
if(content.length == 0)
|
||||
ffGetFileContent(cpuFile, &content);
|
||||
ffGetFileBuffer(cpuFile, &content);
|
||||
|
||||
double herz = ffStrbufToDouble(&content);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user