fix not-compatible 'stat' argument for non-linux OS