19-2318. Discharge or detention of defendant on acquittal. If judgment of acquittal is given on a general verdict and the defendant is not detained for any other legal cause, he must be discharged as soon as the judgment is given, except where the acquittal is because of a variance between the proof and the indictment, which may be obviated by a new indictment, the court may order his detention to the end that a new indictment may be preferred, in the same manner and with like effect as provided in case where the indictment does not state a public offense.
[(19-2318) Cr. Prac. 1864, sec. 418, p. 263; R.S., R.C., & C.L., sec. 7932; C.S., sec. 9003; I.C.A., sec. 19-2218.]