fix: handle EINTR correctly in get_cpu_mask_from_sysfs
[libside.git] / src / smp.c
index 9788e93198e4433ebb12933f0e96a01025706d6f..60f69ac9a439810a2b1d7052308ca2a015bbc1d5 100644 (file)
--- a/src/smp.c
+++ b/src/smp.c
@@ -157,7 +157,7 @@ int get_cpu_mask_from_sysfs(char *buf, size_t max_bytes, const char *path)
 
                total_bytes_read += bytes_read;
                assert(total_bytes_read <= max_bytes);
-       } while (max_bytes > total_bytes_read && bytes_read > 0);
+       } while (max_bytes > total_bytes_read && bytes_read != 0);
 
        /*
         * Make sure the mask read is a null terminated string.
This page took 0.022377 seconds and 4 git commands to generate.