464. Effect of omission to frame, or absence of, or error in charge -
(1) No finding, sentence or order by a Court of competent jurisdiction shall be deemed invalid merely on the ground that no charge was framed or on the ground of any error, omission or irregularity in the charge including any misjoinder of charges, unless, in the opinion of the Court of appeal, confirmation or revision, a failure of justice has in fact been occasioned thereby.
(2) If the Court of appeal, confirmation or revision is of opinion that a failure of justice has in fact been occasioned, it may
(a) in the case of an omission to frame a charge, order that a charge be framed and that the trial be recommenced from the point immediately after the framing of the charge;
(b) in the case of an error, omission or irregularity in the charge, direct a new trial to be had upon a charge framed in whatever manner it thinks fit :
Provided that if the Court is of opinion that the facts of the case are such that no valid charge could be preferred against the accused in respect of the facts proved, it shall quash the conviction.