From a CBS article about police agencies selling unwanted firearms:
Like Philadelphia, every department we reached out to has traded used weapons back to a federally licensed firearms dealer in exchange for a discount on new firearms purchases.
...
Of the data we uncovered about the 52,000 former police weapons found at crime scenes, the ATF wouldn't reveal which police departments once owned those weapons.