Tampa police Cpl. Richard Blasioli was on duty early Thursday morning, driving an unmarked 2001 Ford Expedition, when he saw a 1999 Toyota Solara cruising the wrong way down a road.
He said the driver, a 28-year-old man, swerved the car toward the police vehicle, and 24-year-old man leaned out of the passenger window and threw the can, hitting Blasioli's right front fender.
Officers arrested the pair within minutes.
Both men were charged with throwing a deadly missile at an occupied vehicle, and the passenger faces an additional drug possession charge.
They were later released on bail.
Information from: The Tampa Tribune, http://www.tampatrib.com