mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
fix compiler warning about unused result of fscanf
This commit is contained in:
@@ -114,9 +114,9 @@ static void printResolutionDRMBackend(FFinstance* instance)
|
||||
result->width = 0;
|
||||
result->height = 0;
|
||||
result->refreshRate = 0;
|
||||
fscanf(modeFile, "%ix%i", &result->width, &result->height);
|
||||
|
||||
if(result->width == 0 || result->height == 0)
|
||||
int scanned = fscanf(modeFile, "%ix%i", &result->width, &result->height);
|
||||
if(scanned < 2 || result->width == 0 || result->height == 0)
|
||||
--modes.length;
|
||||
|
||||
fclose(modeFile);
|
||||
@@ -349,7 +349,7 @@ static bool printResolutionXrandrBackend(FFinstance* instance)
|
||||
ffListInitA(&data.results, sizeof(ResolutionResult), 4);
|
||||
|
||||
for(int i = 0; i < ScreenCount(data.display); i++)
|
||||
xrandrHandleScreen(&data, ScreenOfDisplay(data.display, i));
|
||||
xrandrHandleScreen(&data, ScreenOfDisplay(data.display, i));
|
||||
|
||||
if(data.results.length == 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user