If the court directs the case to be resubmitted, or an information to be filed, the defendant, if already in custody, shall remain, unless he or she is admitted to bail; or, if already admitted to bail, or money has been deposited instead thereof, the bail or money is answerable for the appearance of the defendant to answer a new indictment or information; and, unless a new indictment is found or information filed before the next grand jury of the county is discharged, the court shall, on the discharge of such grand jury, make the order prescribed by Section 997.
Ca. Pen. Code § 998