Merge pull request #3454 from matt335672/coverity_fix

Fix coverity warning concerning unchecked return
This commit is contained in:
matt335672
2025-03-10 20:53:43 +00:00
committed by GitHub
+2 -1
View File
@@ -4294,7 +4294,8 @@ g_fips_mode_enabled(void)
if (fd >= 0)
{
if (read(fd, buff, sizeof(buff)) > 0)
ssize_t res = read(fd, buff, sizeof(buff));
if (res > 0 && (size_t)res < sizeof(buff))
{
rv = (buff[0] != '0');
}