The shooter was Mainak Sarkar, said Officer Jenny Houser, a city police spokeswoman.

Highlights Mainak Sarkar had killed a professor at UCLA before taking his own life.

Mainak Sarkar was a doctoral candidate at the school.

The shooting prompted the campus to close for 2 hours on Wednesday.

The gunman who killed a UCLA professor has been identified as his former doctoral student Indian-American Mainak Sarkar, who had accused him of stealing his computer code and giving it to someone else, a media report said.Mainak Sarkar, an alumnus of IIT-Kharagpur, shot and killed professor William Klug in a small office in University of California Los Angeles (UCLA) before killing himself on Wednesday, The Los Angeles Times reported, citing sources.The shooting prompted a complete lockdown of the campus and deployment of hundreds of police officers as well as federal agents.All university classes were cancelled on Wednesday. The lockdown was lifted shortly after noon. Some 43,000 students are enrolled at the UCLA campus, according to its website.Klug, 39, was an associate professor of mechanical and aerospace engineering and had been the target of Mainak Sarkar's anger on social media for months, the paper said.He accused the professor of stealing his computer code and giving it to someone else, it said."William Klug, UCLA professor is not the kind of person when you think of a professor. He is a very sick person. I urge every new student coming to UCLA to stay away from this guy," Mainak Sarkar wrote on March 10."He made me really sick. Your enemy is my enemy. But your friend can do a lot more harm. Be careful about whom you trust," he wrote.In his doctoral dissertation, submitted in 2013, Mainak Sarkar had expressed gratitude to Klug for his help and support, the paper said. "Thank you for being my mentor," he wrote.Before enrolling at UCLA, Mainak Sarkar earned a master's degree at Stanford University, according to his LinkedIn page.In 2000, he graduated from the Indian Institute of Technology, Kharagpur with a degree in Aerospace Engineering.He also had a stint as a research assistant at the University of Texas and worked as a software developer.After UCLA, Mainak Sarkar worked remotely as an engineering analyst for an Ohio-based rubber company, Endurica LLC where he worked until August 2014.