1464. An agent or servant of the State or of a legal person established in the public interest does not cease to act in the performance of his duties by the mere fact that he performs an act that is illegal, unauthorized or outside his competence, or by the fact that he is acting as a peace officer.