Stop processing unit_get_actions when the request is invalid.

Reported by Andreas Rosdal <andreasr>
Patch by Andreas Rosdal <andreasr>

See bug #21900

git-svn-id: svn://svn.gna.org/svn/freeciv/trunk@24769 a0f10bec-cc02-0410-94fc-a9cfff90b4cd