An Indian gay rights activist held up a placard against Section 377 during a protest against the Supreme Court ruling reinstating a ban on gay sex in Kolkata on Dec. 15, 2013. Agence France-Presse/Getty Images

A man has been arrested under India’s law banning homosexual acts after his wife lodged a complaint against him for allegedly having sex with a man.

The arrest in Bangalore is thought to be one of the first to be filed since India’s Supreme Court reintroduced a law against gay sex in December last year.

Police in Bangalore registered a case on Oct. 20 against the man who has not been named for cheating and under Section 377 of the Indian Penal Code which outlaws gay sex, said Sandeep Patil, a deputy commissioner of police in the southern city.

The man was arrested on Sunday and released on bail on Wednesday. A lawyer representing him wasn't immediately available for a comment.

The man’s 31-year-old wife told police that they had been married for nearly 11 months but never had sexual relations, police say. According to the woman, her husband had several male visitors in their house when she was not around, which raised her suspicion about his sexual inclinations, police said. She set up a hidden camera in the house and caught him on film having sex with another man while she was away, Mr. Patil said.

The case brings the focus back onto a colonial-era law reinstated last year in India which makes consensual sex between same-sex adults punishable by a prison term of up to 10 years. India’s gay community raised fears that bringing back the law would expose them to harassment from the police and intimidation from family members in the conservative country.

This case "really changes the terms of the debate (on homosexuality) as far as the courts are concerned," said Danish Sheikh, a lawyer with Alternative Law Forum, an agency fighting for the decriminalization of gay sex in India.

Mr. Sheikh said the top court in its judgment banning homosexual acts last year suggested that the dangers of Section 377 existed only through misuse--blackmailing and extortion--and that misuse of a law cannot be reason to declare it unconstitutional.

The court didn't really consider the danger lurking from privacy violation, saying there will not be any complainant when two consenting adults have sex in private, Mr. Sheikh said.

The court suggested that the possibility of a third party complaining was remote, according to Mr. Sheikh.

"Now what we have here is a very clear case of such a possibility."

For breaking news, features and analysis from India, click here and follow WSJ India on Facebook.