Split a utility function not to use goto statement.