git.el: Reset the permission flags when changing a file state.