George Matchett, whose address was given as the Simon Community Hostel in Lisburn, appeared by way of videolink from Magilligan prison last Friday at Craigavon Magistrates Court.
He admitted unlawful possession of cannabis and cocaine on May 12 last year.
The court heard that a search under warrant at the defendant’s address at the time uncovered small quantities of cocaine in the kitchen and cannabis in the living room.
Defence barrister Aaron Thompson said Matchett had a release date of April 22.
He explained that his client took the decision to get hostel accommodation and moved to Lisburn and things tailed off but matters caught up with him.
District Judge, Mrs Bernie Kelly, said if these matters had been before the court when he was sentenced for the other offences he would have been unlikely to have received a longer sentence.
She imposed three months in custody on each of the two charges.