At least 13 inmates were killed and 15 injured in a shoot-out in a prison in Panama on Tuesday.
Officials said they found three AK-47 assault rifles and five pistols.
President Laurentino Cortizo said an investigation would be launched into how the guns got into La Joyita jail east of the capital, Panama City.
"These firearms didn't fall out of the sky, there was obviously some type of cooperation there for firearms to be brought in," he said.
President Cortizo said he would meet his security council on Wednesday to discuss how to put a stop to guns being smuggled into jails.
"It's something we have to put a stop to. A few weeks ago a search was carried out [in the prison] and arms were found, and now again, so someone is letting these guns in," he said.
The shooting started at 14:00 local time (19:00 GMT) in cell block 14. Prison officials said that inmates are housed in blocks according to their gang affiliation.
The assistant director of Panama's National Police, Alexis Muñoz, said that the shoot-out was between members of the same gang who had "an internal disagreement".
While La Joyita is notorious for overcrowding, this is among the deadliest recorded prison fights in the Central American country.
No prisoners escaped during the fight, officials said.