(b) divulging or communicating to a court in the course of any criminal proceedings any matter or thing coming under the notice of the person in the performance of official duties or in the performance or exercise of a function or power referred to in subsection (1); or