Alan Garcia, the former president of Peru, shot himself early Wednesday as police officers arrived at his home in Lima to arrest him in connection with a bribery investigation, according to local media reports.

In this July 11, 2011 file photo, Peru’s outgoing President Alan Garcia, left, ride the soon to be inaugurated Line 1 electrical train system in Lima, Peru. AP Photo/Martin Mejia, File

Garcia was taken to the Casimiro Ulloa hospital in the Peruvian capital, according to reports.

Garcia, 69, served twice as president of Peru — first from 1985 to 1990 and again from 2006 to 2011 — as the leader for the center left Aprista Party. He ran again for president in 2016, but won less than 6 percent of the vote.

In November, a Peruvian court barred Garcia from leaving the country amid an investigation into allegations that he received illegal payments from Brazilian construction giant Odebrecht. The former president fled to Uruguayan embassy in Lima and sought political asylum, but his request was refused.