Penal Code Section 78
Act done pursuant to the judgment or order of a Court
78. Nothing which is done in pursuance of, or which is warranted by the judgment or order of a Court, if done while such judgment or order remains in force, is an offence, notwithstanding the Court may have had no jurisdiction to pass such judgment or order, provided the person doing the act in good faith believes that the Court had such jurisdiction.
Please refer to the Attorney General's Chamber of Malaysia's website for the latest law.