If we want to alleviate hunger, poverty, famine, unemployment, etc., it'd probably be better to actually invest in space exploration and colonization, rather than throw the money at corrupt dictatorships. Expansion into space would provide a litany of new markets ripe for exploitation. We'd have new science and technological industries popping up not only in the first world countries and industrializing nations like China and India, but it might also spur industrial growth in the third world. Plus, if space colonization ends up being successful, those colonies will become immigration havens for poverty-stricken peoples searching for new opportunities.
In short, if we really want to alleviate world poverty, then we have to create new markets and opportunities for those people. There's no riper place than space, right now. And I also mean "alleviate," not "solve." There's no currently feasible way to solve the problem of poverty and famine, and taking money from the space program to throw at those issues will neither "solve" them, nor even "alleviate" them.
Secondly, there's no better catalyst for innovation than necessity. We need not divert funds from space exploration/colonization to spend solely on environmental and energy issues, because two of the major obstacles of colonization are problems of environment and energy. Since things in space have to go long periods of time without refueling/resupplying, how do we make things more efficient? How do we deal with inhospitable climates? How may we best utilize the limited sources of energy there are in space? Dealing with these problems will spur possibly more innovation in energy/environmental studies than if we just looked at the problem from down here.