Should not be a problem if you are traveling with the same airline, since in the worst case scenario they will get you a seat in a different flight.
Otherwise 3 hours should be just the limit, since you should expect delays in the passport checkpoint and leave time for terminal change.
Should not be a problem if