This situation exposes a weakness in Utlilitarian ethics. If Utilitarianism broadly advocates "the greatest good for the greatest number," how does one balance a slight good for a relatively large number of people against a much more substantial good for a small number?
In this case, we do not know how many people have complained about the man sleeping in the park, or how uncomfortable it makes them. It is therefore very difficult to balance their discomfort against the utility afforded to him by sleeping on the park bench. Since there is a law against sleeping on the park bench, the police have a moral as well as a legal duty to move the man, but there is a competing moral duty not to create further suffering for a person who is already in a bad situation. The ethics of care, which focus on the individual rather than the general moral principle, would privilege the second duty.
One Utilitarian approach to this problem would be to provide a better place for the man to sleep. The police might be able to find him a room in a local shelter or hostel, or even provide him with a bed in a cell for a few hours, if that is really all the time he requires. This might remove the concern for local residents. It would ameliorate the man's situation by providing him with a secure place to sleep.