comma before past participle: the professor, opposed to carrying out


Senior Member
Is comma correctly used here? Is the sentence correct?

The professor, opposed to carrying out the project, made a comment on the report.
  • Have you been told by your teacher that there is something wrong with the sentence?
    As it is written, it means that the professor commented on the report because he was opposed to the project.
    I should have said that if you take away the commas the meaning changes.
    Can you see the difference?