Details
-
Bug
-
Resolution: Fixed
-
Minor
-
Lustre 2.9.0
-
3
-
9223372036854775807
Description
In llapi_obd_statfs() we have:
fd = open(path, O_RDONLY);
if (errno == EISDIR)
fd = open(path, O_DIRECTORY | O_RDONLY);
Second, if open() succeeds then the value of errno is arbitrary and the file descriptor may be leaked if errno was previously set to EISDIR.
Also note that open() will never set errno to EISDIR when write access is not requested.