Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(maint) Refactor aix mountpoints reading
Previously, the AIX mountpoint resolver would check each line of the `mount` command output to check if it matches the header of the table, so it can be skipped. This is not efficient and it can cause many problems, such as not skipping the first line of the output if spaces are not present before `node`, therefore considering the header of the table as a mountpoint. ``` node mounted mounted over vfs date options -------- --------------- --------------- ------ ------------ --------------- /dev/hd4 / jfs2 Mar 22 08:05 rw,log=/dev/hd8 /dev/hd2 /usr jfs2 Mar 22 08:05 rw,log=/dev/hd8 /proc /proc procfs Mar 22 08:05 rw /dev/hd10opt /opt jfs2 Mar 22 08:05 rw,log=/dev/hd8 /dev/hd3 /var x Mar 22 08:05 rw,nodev,log=/dev/hd3 ``` To fix this, instead of checking a line matches the header, we just simply skip the first 2 lines of the output, removing unnecessary regex expresions and improving performance
- Loading branch information