A California man with a lengthy criminal history pleaded guilty Monday to a firearms charge in order to avoid prosecution for more serious offenses.Tony George Gonsalves, 41, of Manteca, Calif., pleaded guilty to attempted possession of a firearm by an ex-felon. He faces up to five years in prison at his sentencing Nov. 19. In a plea agreement with the district attorney's office, Gonsalves agreed to plead guilty in East Fork Justice Court to driving under the influence of a controlled substance, a misdemeanor.The sentences are to be served concurrently.Following a lengthy discussion Monday, Judge Michael Gibbons offered to allow Gonsalves to reconsider his plea next week.He was arrested at the end of August in a traffic stop, and charged with 12 felonies and misdemeanors including child endangerment for asking his 15-year-old daughter to conceal methamphetamine.On Monday, he denied knowing a .22-revolver was under the seat in the vehicle, but said he was pleading guilty to avoid more serious charges that could mean extensive prison time.He told the judge he and his wife had purchased the vehicle 10 days before the arrest, and it was in her name. He said he knew his wife had a revolver and should have known it was in the truck.As an ex-felon, he is forbidden to possess or have access to firearms.Gibbons said Gonsalves couldn't possess something if he didn't know it was in the car. He also advised the defendant that with his record, there was no guarantee that he would get probation.According to reports, deputies pulled Gonsalves over shortly after midnight Aug. 28 after witnesses reported a pickup truck unable to maintain travel lanes on Highway 395 northbound at Riverview Drive. The vehicle drove into a 25-mph zone at 40 mph and drifted between lanes.The truck was pulled over, and deputies said Gonsalves' speech indicated he was under the influence of a controlled substance.He was unable to produce a driver's license and a records check confirmed it had been suspended, along with the license plate.He identified his 15-year-old passenger as his sister, but the girl acknowledged she was his daughter, and said her 6-year-old sister was in the back. Deputies found the little girl asleep on the truck bench without a seat belt.While deputies were placing Gonsalves under arrest, the 15-year-old asked to use a rest room at the gas station where the vehicle was stopped.After she returned to the vehicle, deputies were contacted by a gas station employee who reported finding what he believed was methamphetamine on the floor of the bathroom. He said the bathroom had been cleaned just prior to the 15-year-old entering the facility.The girl reportedly admitted she tried to destroy the methamphetamine. In addition, she had concealed a clear plastic bag with methamphetamine and three Xanax tablets in her clothing which she turned over to deputies. The teenager admitted her father gave her the drugs after they were pulled over, and told her to dispose of them.The girls were placed in the custody of Child Protective Services.Deputies found a H&R Sportsman .22 revolver under the passenger seat.Gonsalves had credit cards and a driver's license in his pocket which reportedly had been stolen from a U.S. Forest Service vehicle three miles west of Sonora Pass the day before.