PARIS — A judge on Friday threw out a criminal case against a French photographer whose graphic image of a man shot by extremists during the November terrorist attacks in Paris drew the ire of the victim’s family.

The case was brought by the Paris prosecutor’s office.

French criminal law forbids the publication of photographs of survivors of violent crimes, including terrorist acts, without their permission, on the grounds that it could “seriously infringe” on their right to human dignity.

In the photograph, the victim, Cédric Gomet, 30, is seen bloodied and wearing only his underwear.

The judge agreed with Maya Vidon-White, the photographer, and Vincent Tolédano, her lawyer. They had argued that it was an inappropriate use of the law, that no crime was committed, and that the law did not apply because Mr. Gomet was dead when the photo was taken.