The Glock 19 is the sidearm of the majority of the NYPD detectives in the film including Detective Terry Hoitz (Mark Wahlberg) and Detective Allen Gamble (Will Ferrell). Gamble is also seen being forced by Capt. Mauch (Michael Keaton) to carry a wooden version of a Glock as a "holster stuffer" replacement of his service gun after he is talked (by two officers) into shooting his Glock into the ceiling of the police station as a brave stunt, saying all the officers have done it, Gamble falls for it and shoots off a round, prompting all the other officers in the room to draw their weapons on him, Gamble proudly saying "Hey, guys! I did my first desk pop!" Throughout the film, The actors have excellent trigger discipline, as it is hard to notice in most scenes when they are breaking this rule. (IMFDB thanks The Golden Closet for providing the documentation on this gun; also see their sales page for Mark Wahlberg's weapon, here.)
Wooden Gun
One of the gags in The Other Guys begins when Det. Gamble is tricked into performing an "Desk Pop" with his Glock 19 inside of the police station and has his weapon temporarily confiscated and replaced with a wooden gun shaped like a Glock 19 throughout much of the film. (IMFDB thanks The Golden Closet for providing the documentation on this gun, as well as the image seen below.)
Astra 400
One of the robbers who fight Highsmith and Danson in the beginning uses an Astra 400.
Det. Danson (Dwayne Johnson) is seen with what appears to be a nickel Colt Mk IV with pearl grips as his main sidearm. (IMFDB thanks The Golden Closet for providing the documentation on this gun; also see their sales page for the weapon, here.)
Browning Hi-Power
One of the thugs that opens fire on Det. Hoitz in the boardroom uses a Browning Hi-Power.
Smith & Wesson Model 36
Carried by Captain Gene Mauch (Michael Keaton) who works both as the head of the Precinct and at Bed Bath and Beyond.
In some publicity material for the film (such as the poster above), Mark Wahlberg can be seen dual-wielding Desert Eagles with stainless steel finishes, spoofing various John Woo-style movie posters. On the movies web site, Wahlberg is seen firing these, hanging from cables, mocking the poster before crashing into Will Ferrell. Ferrell comments that he dropped his "$1,000 gun". Most Desert Eagles run in range from approximately $1,500-$2,200, making his comment somewhat correct.
SIG-Sauer P220 Sport
In some of the aforementioned publicity material, Will Ferrell can be seen wielding both a Desert Eagle and what appears to be a SIG-Sauer P220 Sport with an accessory rail integrated into the compensator.
FN Minimi/M249
One of the criminals who were chased by Highsmith and Danson in the beginning uses an FN Minimi/M249 Squad Automatic Weapon
SIG SG 556
Used by the Chechen helicopter gunmen shooting at Gamble and Hoitz during the climax
Heckler & Koch MP5A3
The H&K MP5A3 is used by NYPD ESU officers in the film's climax