NEW ORLEANS (AP) — Louisiana's Supreme Court says a former police officer caught in the bedroom of a teenage girl in 2014 can be convicted of malfeasance in office and attempted carnal knowledge of a juvenile — even though both convictions were related to the same incident.

The court's Wednesday ruling was aimed at clarifying the way the constitutional protection against "double jeopardy" is applied in Louisiana courts.

The case involved a former Oakdale officer who was convicted by a jury of both attempted carnal knowledge and malfeasance after he was discovered hiding in the closet of a 15-year-old girl. An appeals court threw out the attempted carnal knowledge conviction, citing double jeopardy protections. But the high court said two crimes were sufficiently different for both the carnal knowledge and malfeasance convictions to stand.