fixed some problems that were introduced by the previous patch
fixed some problems that were introduced by the previous patch

psychoschlumpf/libportage,psychoschlumpf/libportage,larsuhartmann/libportage,larsuhartmann/libportage