A minor who police said accidentally pocket-dialed 911 led authorities to an underage drinking party in York early Sunday morning that prompted a standoff and the arrest of a man allegedly involved in the illegal celebration.

York police said in a statement that they responded to a 911 hangup call at 63 Cider Hill Road around 12:46 a.m.

Sgt. Luke Ernenwein said the dispatcher could hear yelling and people arguing at the other end of the phone line, but there was no one on the line to talk to.

Police, using cellphone towers, identified the approximate location of the 911 call, and when they pulled into the driveway, the homeowner – Leighlon Anderson, 45 – came running out to apologize about the errant call for help.

She was then charged with furnishing/allowing minors to consume alcohol.

“The butt dial was the reason for our involvement,” Ernenwein said, adding that dispatchers receive a lot of pocket dial calls that simply cannot be investigated.

“Butt dialing” or pocket dialing occurs when someone inadvertently presses against a phone while it is in his or her pocket or handbag. The person who receives the call typically hears random background noise. Some smartphones have a 911 emergency button on the screen, which in this case was probably pressed by the phone’s owner, Ernenwein said.

The 911 call early Sunday attracted the attention of York police because it sounded like someone could be in distress, he explained.

After Anderson was charged, York police cleared the residence and left the scene.

But at 1:39 a.m. police received a call reporting that a male at the 63 Cider Hill Road home had pointed a firearm at one of the minors at the party.

Ernenwein said that when police returned to the home, they determined that Joseph David Coreau, 36, of Kittery was hiding in the attic.

Police evacuated the house for safety and surrounded it while waiting for the Southern Maine Special Response Team – a York County SWAT-type unit – to arrive.

Police learned from those evacuated from the house that Coreau was agitated after learning that police had been accidentally called there by one of the minors. Coreau retrieved a gun and pointed it at one of the minors before he retreated to the attic.

He emerged from the attic before the special response team arrived. He was charged with criminal threatening with a dangerous weapon and taken to the York County Jail, where he is being held on $5,000 bail.

Kittery police helped York Police secure the scene and take Coreau into custody.

There were no injuries. Police said they recovered three loaded guns from the attic where Coreau was hiding.