compare st_mode as integer; rm unnecessary string conversion

Per https://github.com/saltstack/salt/pull/4738#discussion_r4050234