gpuclockctl: fix return value of get_gpu_state_amd()

This commit is contained in:
Matthias Gerstner 2019-04-03 16:18:36 +02:00
parent 959c48978b
commit 618997f0b3

View File

@ -303,7 +303,7 @@ static int get_gpu_state_amd(struct GameModeGPUInfo *info)
/* Copy in the value from the file */ /* Copy in the value from the file */
strncpy(info->amd_performance_level, buff, CONFIG_VALUE_MAX - 1); strncpy(info->amd_performance_level, buff, CONFIG_VALUE_MAX - 1);
info->amd_performance_level[CONFIG_VALUE_MAX - 1] = '\0'; info->amd_performance_level[CONFIG_VALUE_MAX - 1] = '\0';
return info == NULL; return 0;
} }
/* /*