A man wanted after a five-month drug investigation was taken into custody when he showed up to visit a friend in jail.

Photo: Bob Joseph/WNBF News (file)

Authorities say 24-year-old Kareem Wilson of Cortland was arrested around 7:45 a.m. on Sunday.

Investigators say Wilson was named in a sealed indictment issued by Cortland County Supreme Court. He was charged with two counts of third-degree criminal sale of a controlled substance.

Officers took Wilson into custody without incident as he entered the parking lot of the sheriff's office. He was planning to visit a friend who was being held at the jail.

Wilson was arraigned in Cortland County court. He was ordered held at the jail without bail.

For breaking news and updates on developing stories, follow @BinghamtonNow on Twitter.