A man brandishing a machete was shot and killed by a New York City cop Tuesday morning after the man refused to drop the weapon and continued to approach the officer, police said.

NYPD Chief of Patrol Terence Monahan said officers arrived at an apartment in the Bronx on Tuesday after obtaining a search warrant. Monahan said police were told the apartment had firearms and drugs inside.

NEW YORK MAN BITES EYE OUT OF SHI TZU, OFFICIALS SAY

Two officers went into the apartment and found a 38-year-old man holding the two-foot blade in a bedroom, Monahan said. The officers allegedly asked the suspect to drop the weapon but he did not and approached the lead officer before one of the cops discharged his firearm, shooting the suspect once in the chest.

An elderly man was also in the apartment during the incident but was not injured. He was taken to the hospital as a precaution, Monahan said.

Monahan said the officers immediately called 911 and the suspect was transported to a hospital where he died. The officers were not injured during the incident.

GROWING MASS OF SEX CRIME CASES CHASED IN LOS ANGELES, LONDON, NEW YORK CITY

The chief of patrol said the suspect was not the man police were initially searching for. A suspect that may have been involved in the search warrant has been arrested.

Monahan did not identify the suspects and the police officers involved in the shooting will be interviewed about the shooting. Neither of the officers were wearing a body camera at the time.

The machete was recovered at the scene and the apartment was being treated as a crime scene.