Venezuelan President Hugo Chavez has met twice with the ailing former Cuban leader Fidel Castro during a short visit to Havana .