He might not have been intoxicated when he passed security.
Improbable, he would have had his bags screened for liquids to enter sterile, and would have had to purchase duty- free in sterile, and find somewhere to imbibe. More likely got through with no-one questioning him. I don't think security screeners would be too inclined to stick their necks out on questioning a captain.... " not my job, mon!"