Police shot and killed a knife-wielding suspect and may have fatally wounded another man Monday night in what investigators believe was a love-triangle dispute in Brooklyn, law enforcement officials said Tuesday.

Francisco Carvajal, 47, was killed by officers who responded to 911 calls of an attack in the seventh-floor apartment of Katazrynza Russo, 35, who had locked herself in the bathroom with her two young children, police said.

Carvajal, who also lived in the building at 820 Ocean Parkway and was believed to be Russo's former boyfriend, was shot numerous times by officers after he refused to drop the knife.

Also killed in the incident was Rafael Laureano, 51, described by law enforcement sources as a champion bodybuilder and Russo's current boyfriend. Laureano was stabbed multiple times by Carvajal and had a wound in his torso that may have been caused by one of the rounds fired by cops, said a law enforcement official who asked not to be identified.

An autopsy to determine the cause of Laureano's death was expected to be completed Wednesday.

"Because of the very close quarters this occurred in, ... he may have been inadvertently struck by a police round," said NYPD spokesman Stephen Davis.

The deadly encounter in Ocean Parkway began about 7:18 p.m. Monday. Officers found the door to Russo's apartment locked but heard screaming and shouting inside. Police breached the door, and Laureano, who was standing in the hallway, ran past the officers into the apartment before he could be stopped, the official said.

Laureano rushed to where Carvajal was pounding on the bathroom door and attempting to break it open with a knife. Carvajal fought with Laureano, stabbing him, before police stopped the assault by firing over a dozen rounds, according to the official.

Police said Carvajal was dead at the scene; Laureano was later pronounced dead at Maimonides Medical Center.

Russo, her son, 6, and daughter, 7, were unharmed.