fixed error when trying to chmod when user is not owner of the file