Both were in operative condition.
Ferguson told police the SACM pistol belonged to his brother, who died about 30 years ago, and was of "no value other than sentimental", but agreed "he should not have had it".
However, he denied ownership or knowledge of the .22, stating he had never seen it before.
Defence counsel Bill Dawkins, arguing for the discharge, said Ferguson had extensive business interests overseas and any conviction would impact his travel.
Mr Dawkins said that in the past month Ferguson had travelled to Dubai, met the Sheikh Sultan and the Crown Prince of Dubai, and delivered 12 milk-fed lambs.
The lambs were worth $300 each and Mr Dawkins said the Sheikh wanted to import them from New Zealand. Initial estimates indicated lambs in the southern South Island could turn a profit of more than $3.8 million and the deal could also involve North Island farms.
Ferguson was also working with the Sheikh and Fonterra to arrange exports of dairy products.
Further, "they want our water", Mr Dawkins said.
The cost of desalination was high and the UAE wanted single-skinned tankers to transport water from New Zealand to them.
The Sheikh was "likely to come to New Zealand in February and March to tie that together", he said.
Ferguson had admitted the offending based on the expanded definition of "possession" under the Act and the consequences of a conviction for the possession of the two pistols, for which he did not hold any ammunition, would be out of proportion.
Mr Dawkins said his client was "not some fat cat trying to get a second chance from the court. He's made his money, I suspect, years ago".
"What he's doing now is helping New Zealanders."
Ferguson was community minded, had hosted after-ball functions on his property, taught claybird shooting, was involved in the Buddy child-mentoring programme and had constructed a jetsprint aqua course on his property, which attracted about 7000 spectators at Easter.
In 2010 Ferguson received a discharge without conviction after admitting discharging a firearm in a public place without reasonable cause, so as to endanger or annoy the public, when he shot and killed a magpie on a grass verge from the passenger seat of a vehicle.
Mr Dawkins said Ferguson took that incident "seriously" and this was not a situation where he was breaching the Act "flagrantly".
"He's asking for this indiscretion not to hold him back from helping others in the community."
Police opposed the discharge, but Judge Bergseng ultimately found the consequences of a conviction would be out of all proportion.
While his previous discharge was an aggravating factor and Judge Bergseng viewed the offending as "moderate", he accepted Ferguson had no knowledge of the .22 pistol.
Mitigating factors included his guilty pleas, that he was an otherwise licensed firearms holder and was "clearly" a man of "otherwise good character".
"What is of concern is that there does appear to be, or there is support for the view that there is, a somewhat cavalier attitude relating to the presence and storage of firearms."
Judge Bergseng exercised his discretion to grant the discharge.
However, he made an order for forfeiture and destruction of both pistols and ordered Ferguson to pay $750 towards the cost of prosecution.