Fix portability issue when checking local facts file permission.
Merge pull request #7543 from yangliping/fix_local_facts_file_checking_portability

Fix portability issue when checking local facts file permission.