Criminal law practice before the Supreme Court of India

Criminal Writs before the Supreme Court.

Illegal detention challenges Lawyer in Supreme Court of India

When a person alleges that his or her personal liberty has been curtailed without legal justification, the challenge is characterised as an illegal detention challenge, a matter that the Supreme Court of India may entertain either under its original jurisdiction for violation of the constitutional guarantee of personal liberty or under its discretionary appellate jurisdiction for extraordinary questions of law and fact arising from lower-court orders. The constitutional foundation for such petitions rests principally upon the guarantee of life and personal liberty enshrined in Article 21, which the Supreme Court has repeatedly interpreted to require that any deprivation of liberty must be sanctioned by a validly enacted law and must be procedurally fair, thereby creating a judicially enforceable standard that lower tribunals must observe. In addition to the constitutional premise, the present procedural framework provides that a writ of habeas corpus, a writ of mandamus, or a writ of certiorari may be invoked before the Supreme Court to compel the production of the detained individual before a competent authority and to examine the legality of the detention, with the choice of writ depending upon whether the petitioner seeks release, a direction to the detaining authority, or a quashing of an unlawful order. Maintainability of an illegal detention petition before the Supreme Court is conditioned upon the existence of a final order or a completed investigative report that has already been acted upon by a lower court, tribunal, or executive agency, because the Supreme Court will not entertain a petition that merely raises a prospective grievance without a concrete operative order to be reviewed. The threshold for the Supreme Court to entertain a petition under its discretionary appellate jurisdiction, commonly invoked through Article 136, requires that the matter involve a substantial question of law, a manifest miscarriage of justice, or a conflict among decisions of various High Courts, thereby ensuring that the Court’s intervention is reserved for issues of exceptional public importance rather than routine appellate review. Practically, the record that gives rise to a Supreme Court illegal detention proceeding is usually the detention order signed by a police officer, magistrate, or prison authority, accompanied by the charge sheet, the remand order, and any subsequent orders of bail, remission, or discharge, all of which must be compiled into a paper-book and filed with the Supreme Court registry in accordance with the prescribed rules of filing. Before filing, the petitioner must ensure that the notice period prescribed for challenging the detention has been respected, that any statutory bar for filing a petition after the expiry of the limitation period has not elapsed, and that the petition is accompanied by a certified copy of the detention order, a verified affidavit stating the facts of the alleged illegality, and a prayer seeking the specific relief of release or direction, because failure to comply with these procedural prerequisites may result in the petition being dismissed on technical grounds without reaching the merits. Once the petition is admitted, the Supreme Court typically lists it for hearing after a preliminary scrutiny of the paper-book, issues a notice to the detaining authority, and may, at its discretion, order the production of the detainee before a designated bench, thereby converting the writ petition into a factual inquiry that tests the legality of the detention on the basis of the material on record and any additional evidence that the parties may be directed to produce. Finally, the litigant must appreciate that a Supreme Court decision in an illegal detention challenge does not constitute a rehearing of the underlying criminal case but rather a determination of whether the procedural safeguards and substantive legal requirements governing deprivation of liberty have been satisfied, and that the consequences of a favorable order may include immediate release, compensation for unlawful confinement, or directions for corrective procedural reforms, whereas an adverse order may leave the original criminal proceedings untouched, subject only to the ordinary appellate route.

Jurisdiction of the Supreme Court to entertain criminal writ petitions challenging illegal detention

The Supreme Court exercises original jurisdiction under Article 32 of the Constitution to entertain writ petitions that allege infringement of personal liberty, thereby permitting a direct challenge to any detention that is claimed to be unlawful, without the necessity of first approaching a High Court. Within this original jurisdiction the Court may issue a writ of habeas corpus, a writ of mandamus, or a writ of certiorari, each of which is selected on the basis of whether the petitioner seeks the physical production of the detainee, a directive compelling the detaining authority to act in accordance with law, or the annulment of a specific order that gave rise to the confinement. The Court’s discretionary appellate jurisdiction, invoked through Article 136, is limited to circumstances where the petition raises a substantial question of law, demonstrates a manifest miscarriage of justice, or reveals a conflict among High Court decisions, thereby ensuring that the apex court intervenes only in matters of exceptional public importance and not as a routine appellate forum. A petition may be entertained only when a final order—such as a remand order, a bail order, a discharge order, or a completion report of investigation—has been issued by a competent authority and has produced a legal effect, because the Supreme Court requires a concrete operative act to review rather than a speculative or prospective grievance. The jurisdictional threshold also demands that the petitioner demonstrate that the statutory limitation period for filing a writ has not elapsed, that any statutory notice requirement—such as the notice to the detaining authority under the applicable procedural law—has been complied with, and that the petition is accompanied by a certified copy of the detention order and a verified affidavit, because failure to satisfy these prerequisites invites dismissal on jurisdictional grounds without any substantive consideration. Upon acceptance of the petition, the Supreme Court registry conducts a preliminary scrutiny of the paper-book, ensuring that the compilation includes the original detention order, the charge sheet, any remand or bail orders, the investigative report, and any subsequent orders, because the completeness of the record determines whether the bench can proceed to substantive adjudication without requiring further supplementation. If the registry finds the record deficient, the Court may issue a notice directing the petitioner or the detaining authority to furnish the missing documents within a stipulated time, and such a deficiency, if not remedied, can lead to the dismissal of the petition on technical grounds, thereby underscoring the importance of meticulous preparation of the paper-book. When the petition is listed for hearing, the bench may, at its discretion, order the immediate production of the detainee before the Court, thereby converting the writ proceeding into a factual inquiry that tests the legality of the detention on the basis of the material on record and any additional evidence that the parties may be directed to produce, because the Supreme Court retains the power to examine the detainee’s condition and the circumstances of confinement to assess whether procedural safeguards have been observed. A favorable order may direct the immediate release of the detainee, may stay any pending criminal proceeding, may direct the detaining authority to file a fresh charge sheet, or may award compensation for unlawful confinement, whereas an adverse order typically leaves the underlying criminal case untouched, permitting the petitioner to pursue ordinary appellate remedies in the regular criminal jurisdiction. Consequently, the Supreme Court’s jurisdiction over illegal detention challenges operates as a safeguard that not only checks the legality of the deprivation of liberty but also shapes the procedural conduct of lower courts and law-enforcement agencies, because the prospect of an apex-court intervention compels adherence to constitutional guarantees, meticulous record-keeping, and timely compliance with statutory mandates, thereby reinforcing the rule of law in the criminal justice system.

Maintainability criteria and limitation periods for filing an illegal detention challenge before the Supreme Court

For a petition challenging illegal detention to be deemed maintainable before the apex court, the petitioner must demonstrate the existence of a final, operative order that has already produced a legal effect, such as a detention order signed by a police officer, a magistrate’s remand order, a bail order, or a discharge order, because the Supreme Court will not entertain abstract grievances lacking a concrete adjudicative act upon which review may be predicated. The petitioner must also establish locus standi by showing that he or she is either the person who is detained, a legally authorized representative such as a next-of-kin, a guardian, or an attorney, or a public-interest litigant whose involvement is justified by the fundamental nature of the personal liberty right at stake, since the Court requires a direct or legally recognized interest in the deprivation of liberty before it can entertain the writ. In addition, the petitioner is required to have exhausted any alternative statutory or administrative remedies that are expressly provided for under the applicable procedural law, for example by first approaching the designated magistrate or the supervisory authority, unless extraordinary circumstances such as concealment of the detention or imminent danger to life render such exhaustion impracticable, because the Supreme Court’s discretionary jurisdiction is predicated on the principle that it should not supplant ordinary appellate mechanisms where those are available. The filing must further comply with any statutory bar that the specific legislation governing the detention imposes, for instance a provision that disallows a habeas corpus petition after a prescribed period, and where no such specific bar exists the general limitation framework applicable to writ petitions under the Limitation Act must be observed, thereby ensuring that the petition is not time-barred at the moment of presentation. The limitation period is ordinarily interpreted as a reasonable time measured from the date on which the petitioner became aware of the detention or from the date of the operative order, and judicial pronouncements have frequently treated a period of three months as the benchmark for “reasonable” in the context of personal liberty challenges, although the Court retains discretion to extend this period where the petitioner can establish that the delay was caused by factors beyond his or her control, such as deliberate concealment of the detention by the authorities. If the petition is filed after the lapse of the applicable limitation, the Court is empowered to dismiss it on technical grounds without reaching the substantive merits, unless the petitioner can satisfy the Court that the delay was justified by exceptional circumstances and that the interests of justice demand a departure from the strict temporal bar. Prior to filing, the petitioner must compile a comprehensive paper-book that includes the original detention order, all subsequent orders affecting the custody, a certified copy of the charge sheet if any, the verified affidavit narrating the factual matrix, proof of service of any statutory notice to the detaining authority, and any other documentary evidence required by the registry, because the completeness of the record is a prerequisite for the Court’s preliminary scrutiny and any deficiency may result in a show-cause notice or outright dismissal. The Supreme Court registry, upon receipt of the petition, conducts an initial examination to ascertain whether the maintainability requisites and the limitation criteria have been satisfied, and where the registry identifies a lacuna—such as an absent copy of the detention order or an apparent breach of the limitation—it may issue a directive to the petitioner or the opposite party to furnish the missing material within a stipulated timeframe, failure to which constitutes a ground for dismissal on procedural infirmity. When the petition survives the preliminary stage, the Court may grant interim protection in the form of a stay of the detention pending final determination, may order the immediate production of the detainee before the bench, and may direct the detaining authority to preserve the status quo, thereby preventing irreversible prejudice while the substantive legality of the confinement is examined. Conversely, a dismissal on the basis of non-maintainability or limitation lapse leaves the detainee in continued custody, compels the petitioner to pursue ordinary criminal appeals or revisionary remedies, and may foreclose the possibility of obtaining immediate relief through the writ jurisdiction, underscoring the critical importance of timely and procedurally flawless filing. Consequently, litigants seeking to challenge illegal detention before the Supreme Court must act expeditiously after the operative order, ensure strict compliance with any statutory notice and limitation requirements, and prepare an exhaustive paper-book, because any defect in these foundational aspects can preclude the Court from entertaining the petition and thereby deny the aggrieved party the constitutional safeguard of personal liberty.

Preparation and authentication of the paper-book and record for Supreme Court scrutiny in illegal detention matters

The paper-book, which constitutes the sole documentary foundation upon which the Supreme Court will evaluate an illegal detention petition, must be assembled in strict accordance with the registry’s prescribed format, incorporating every operative instrument that gave rise to the deprivation of liberty, including the original detention order, any subsequent remand, bail or discharge orders, and the complete charge sheet, if any. Each document incorporated into the paper-book must be a certified true copy, authenticated by the officer who originally issued the order or by a gazetted officer authorized to attest public documents, and must bear the requisite seal, signature and date to satisfy the statutory requirement that the record presented to the apex court be indubitably authentic and free from any material alteration. In addition, the petitioner must file a verified affidavit accompanying the paper-book, wherein the deponent solemnly declares, under oath, the factual matrix of the alleged illegality, the identity of the detaining authority, and the unavailability of any alternative remedy, and this affidavit must be notarized or affirmed before a magistrate to ensure that the court may rely upon it as a sworn statement of truth. The assembled documents must then be arranged in strict chronological order, each bearing a docket number, a brief description of its nature, and a cross-reference index that enables the registry clerk and the bench to locate any particular order or report within seconds, thereby preventing delays that could arise from a disorganized compilation and ensuring that the court’s time is devoted solely to substantive adjudication. Upon receipt of the paper-book, the Supreme Court registry conducts a preliminary scrutiny, employing a checklist that verifies the presence of the certified detention order, the authenticated charge sheet, all subsequent orders, the verified affidavit, and the statutory notice of intended challenge, and should any item be found missing or improperly authenticated, the registry issues a show-cause notice demanding rectification within a prescribed period, failure of which may culminate in outright dismissal of the petition. If the registry determines that the paper-book satisfies all formal requisites, it affixes a seal of acceptance and forwards the record to the bench, at which stage the court may, even before hearing, grant interim protection by staying the detention, ordering the immediate production of the detainee, or directing the detaining authority to preserve the status quo, thereby preventing any irreversible prejudice while the substantive legality of the confinement is examined. In jurisdictions where electronic filing is permitted, the Supreme Court rules require that each scanned document be accompanied by a digital signature of the authorized signatory, and that the electronic paper-book be uploaded through the e-court portal in a single compressed file, after which the registry validates the integrity of the digital hash to confirm that no post-submission alteration has occurred, thereby extending the principle of authentication from physical seals to cryptographic verification. Consequently, meticulous preparation and flawless authentication of the paper-book not only forestalls procedural objections that could otherwise lead to dismissal or curtailment of interim relief, but also equips the bench with a reliable evidentiary foundation upon which it can assess whether the detention order complied with the procedural safeguards of the applicable criminal procedure law, decide on the propriety of bail or remand, and, where appropriate, issue a direction for immediate release, compensation, or remedial instruction to the detaining agency. Therefore, litigants and counsel must allocate sufficient time and resources to procure certified copies, obtain requisite signatures, draft a comprehensive affidavit, index the documents meticulously, and, where electronic filing is applicable, ensure digital integrity, because any lapse in this exhaustive preparation chain can result in the Supreme Court refusing to entertain the petition, thereby depriving the aggrieved party of the constitutional safeguard against unlawful confinement.

Framing of relief: habeas corpus, bail, and directions for release – substantive and interim aspects

The petitioner must articulate the sought remedy in a distinct prayer clause that delineates, with unequivocal precision, whether the relief pertains to a writ of habeas corpus, a grant of bail, or a specific direction for release, because any ambiguity may invite the Court to deem the petition procedurally defective and consequently refuse to consider the merits. When the prayer invokes habeas corpus, the Court expects a request that the detaining authority be ordered to produce the body of the petitioner before a designated bench, accompanied by a declaration that the detention lacks legal foundation under the constitutional guarantee of personal liberty, thereby rendering the order a substantive determination of unlawful confinement. If the petitioner seeks bail, the prayer must specify that the Court exercise its inherent power to grant interim liberty pending trial, articulate the grounds such as the absence of flight risk, the presence of sufficient sureties, and the necessity of preserving the presumption of innocence, because bail relief operates on a distinct evidentiary threshold separate from the habeas corpus inquiry. A direction for release, distinct from the binary outcome of habeas corpus, may be framed to command the detaining authority to discharge the petitioner without prejudice, to withdraw any pending remand order, or to file a fresh charge sheet within a stipulated period, thereby addressing procedural irregularities while preserving the continuity of the criminal investigation. The Court distinguishes between interim relief, which is intended to preserve the status quo and prevent irreversible injury while the substantive question of legality is examined, and substantive relief, which constitutes a final determination that the detention is unlawful and therefore mandates immediate discharge, compensation, or corrective orders, because conflating the two may prejudice the parties and undermine procedural fairness. In framing the prayer, the petitioner must also include a fallback or alternative relief clause that contemplates the possibility that the Court may find the detention partially lawful, thereby requesting a modification of the remand period, a direction to file a supplementary charge sheet, or an order for periodic judicial review, because the presence of a well-crafted alternative demonstrates to the Court that the petitioner has contemplated the spectrum of legal outcomes. During the record examination, the bench scrutinises the certified copies of the detention order, the statutory notice of challenge, the affidavit narrating the factual matrix, and any material evidentiary annexures, applying the legal test that the detention must be founded upon a valid authority, a cognizable offence, and compliance with procedural safeguards such as the right to be informed of grounds of arrest, because any defect in these foundational elements directly defeats the claim for habeas corpus or bail. When the Court grants interim protection, it may issue an order staying the detention, directing the custodian to keep the petitioner in the same conditions pending final determination, or ordering the immediate appearance of the detainee before the bench, thereby ensuring that the petitioner is not subjected to further hardship while the substantive merits are being adjudicated. Conversely, a substantive grant of habeas corpus or bail results in an immediate cessation of the unlawful confinement, obliges the detaining authority to release the petitioner forthwith, may order the restoration of any forfeited property or wages, and can include a directive that the investigating agency file a fresh charge sheet within a time-frame prescribed by the Court, thereby rectifying the procedural lapse that gave rise to the illegal detention. If the prayer is inadequately framed, omits the requisite specificity, or fails to satisfy the procedural prerequisites such as certification of documents or compliance with the limitation period, the registry may issue a show-cause notice that, if not remedied, culminates in dismissal of the petition, thereby leaving the detainee in continued custody, precluding any interim stay, and compelling the petitioner to pursue alternative remedies in the ordinary criminal appellate hierarchy.

Procedural steps for listing, notice, and surrender of the respondent in Supreme Court illegal detention petitions

Once the petition accompanied by a complete paper-book is deposited with the Supreme Court registry, the clerk first verifies that the filing fee has been paid, that the petition bears the requisite verification affidavit, and that the statutory notice to the detaining authority, if any, has been duly annexed, because any deficiency at this preliminary stage triggers an automatic show-cause notice that must be complied with before the matter can be entered into the Court’s listing calendar. After the registry issues a compliance certificate confirming that the record satisfies the formal checklist, the petition is transmitted to the relevant bench registrar who, in consultation with the bench’s master calendar, assigns a provisional listing date that reflects the urgency of personal liberty claims, the availability of the respondent for production, and the need to avoid undue delay that could render any interim protection ineffective. The provisional listing is entered into the Supreme Court’s electronic case management system, and the registrar subsequently dispatches a formal notice to the respondent, usually the police superintendent or prison superintendent, requiring that the detained individual be produced before the designated bench on the stipulated date, and the notice also stipulates the precise time, the mode of appearance, and the consequences of failure to comply, including the possibility of contempt proceedings. Upon receipt of the notice, the respondent is obligated under the applicable criminal procedure law to ensure that the detainee is physically present in the custody of the authority that issued the original order, and the authority must also submit a certified copy of the detention order together with any subsequent remand or bail orders to the Court, because the bench requires the original operative documents to assess whether the detention complies with statutory safeguards before entertaining any substantive argument. The bench, after confirming that the respondent has complied with the production requirement, may either proceed to hear the petition on the merits or, if the record reveals glaring procedural irregularities such as lack of information of grounds of arrest, may issue an immediate interim order directing the release of the detainee pending a full hearing, thereby exercising its inherent power to prevent the perpetuation of an unlawful confinement. In circumstances where the respondent contests the jurisdiction of the Court or raises a counter-claim that the detention was authorized by a subsequent order issued after the filing of the petition, the bench may adjourn the matter to a later date, grant a limited extension for filing supplementary material, and simultaneously issue a stay on any further custodial action, because the Supreme Court seeks to balance the rights of the petitioner with the need to preserve the integrity of ongoing investigations. Should the respondent fail to appear before the bench on the appointed day despite having been duly served with the notice, the registrar is empowered to record the non-appearance as a contempt of the Supreme Court, to issue a warrant for the arrest of the responsible officer, and to direct the immediate release of the detainee, because the Court treats wilful non-compliance with a production order as a direct affront to its authority and as a ground for invoking its contempt jurisdiction. Once the bench renders a final order—whether granting habeas corpus, directing bail, or ordering release—the registry annotates the case file with the operative direction, updates the electronic docket to reflect the change in custody status, and notifies the detaining authority that any further detention beyond the date specified in the order will constitute illegal confinement liable to compensation, thereby ensuring that the final adjudication has immediate practical effect on the status of the detainee. If, after the issuance of the final order, the detaining authority files an application for reconsideration on the ground of newly discovered evidence, the Supreme Court may entertain such an application only after the petitioner is given an opportunity to oppose, and the bench may either modify the earlier direction or reaffirm it, but any modification that results in continued detention will be subject to a fresh assessment of the procedural safeguards, because the Court’s overriding concern remains the protection of personal liberty against arbitrary deprivation. Consequently, the procedural choreography of listing, issuance of notice, and surrender of the respondent operates as a tightly regulated sequence that, when faithfully observed, secures the Court’s ability to intervene promptly in unlawful confinement cases, while any deviation—such as delayed filing, incomplete paper-book, failure to produce the detainee, or non-compliance with interim orders—invites dismissal, contempt sanctions, or the affirmation of the detention, thereby underscoring the paramount importance of meticulous adherence to the Supreme Court’s procedural regime for illegal detention petitions.

Assessment of investigation defects, evidentiary gaps, and statutory bars influencing Supreme Court decisions

When an illegal detention petition reaches the Supreme Court, the first substantive exercise undertaken by the bench consists of a meticulous assessment of any defects in the investigative process, any lacunae in the evidentiary record, and any statutory impediments that may preclude the exercise of jurisdiction, because the Court’s power to intervene is predicated upon the existence of a demonstrable violation of procedural safeguards that underlie the legitimacy of the detention. The documentary corpus that the petitioner must assemble for this purpose typically includes the original First Information Report, the formal charge sheet, the final investigation report signed by the investigating officer, any forensic or medical examination reports, the remand order, and any subsequent orders of bail or discharge, each of which must be presented as a certified true copy, because the Court relies on the authenticity of these instruments to identify omissions such as failure to record the grounds of arrest, failure to disclose material witnesses, or failure to comply with statutory time-limits for filing the charge sheet. In evaluating whether such omissions rise to the level of a fatal defect, the Court applies the legal test that the investigation must have been conducted in accordance with the applicable criminal procedure law, that the accused must have been afforded the right to be informed of the grounds of arrest, that the evidence must have been collected in a manner that satisfies the standards of relevance, materiality and admissibility, and that any statutory bar—such as a limitation period prescribed for filing a habeas corpus petition or a statutory provision barring review after a certain stage of the criminal proceeding—has not been triggered, because the presence of any one of these infirmities can render the detention order ultra vires and therefore susceptible to nullification. The bench, after receiving the paper-book, may direct the registry to issue a show-cause notice to the investigating agency requesting clarification of any identified gaps, may order an independent forensic re-examination of seized material, may summon the investigating officer for oral testimony, and may even appoint a special master to compile a comprehensive summary of the evidentiary chain, because such procedural interventions enable the Court to ascertain whether the missing links in the record are merely technical oversights that can be cured or whether they reflect a systemic failure that defeats the very foundation of lawful custody. Consequently, when the Supreme Court concludes that the investigation suffered a material defect, that the evidentiary record contains an insurmountable gap, or that a statutory bar precludes further judicial scrutiny, it may either dismiss the petition on the ground of non-maintainability, may grant interim relief ordering the immediate release of the detainee pending a fresh investigation, may direct the lower court to re-file a charge sheet within a time-frame prescribed by the applicable procedural law, may stay any pending remand or bail order, and may award compensation for unlawful confinement, whereas a finding that the defects are curable but not fatal often results in the Court directing the respondent to remedy the specific lapse while keeping the detention in place, thereby illustrating how the assessment of investigative and evidentiary shortcomings directly shapes the spectrum of relief, the status of bail, the possibility of remand, and the ultimate fate of the custodial order.

Consequences of dismissal, interim orders, or grant of relief on custody, pending trial, and future criminal proceedings

When the Supreme Court dismisses an illegal detention petition on the ground of non-maintainability, procedural defect, or lapse of the prescribed limitation, the immediate legal consequence is that the custodial status of the petitioner remains unchanged, the detention continues under the operative order, and no stay or protective direction is imposed by the apex court. Because the dismissal does not invalidate the underlying charge sheet or the remand order, the lower-court trial proceeds on the original schedule, the accused remains subject to any bail conditions already imposed, and the prosecution retains the full spectrum of evidentiary and procedural tools available under the applicable criminal procedure law. If the petitioner elects to challenge the dismissal through a review or curative petition, the Supreme Court may entertain the application only after the petitioner demonstrates a clear error apparent on the face of the record, and until such review is disposed of, the custodial order continues to bind the petitioner, thereby preserving the status quo and preventing any premature release that could jeopardise the integrity of the ongoing investigation. Conversely, when the Supreme Court issues an interim order staying the detention, the stay operates as a temporary injunction that obliges the detaining authority to refrain from further custodial action, to maintain the detainee in the same conditions pending final determination, and to suspend any pending remand or extension of custody unless expressly authorized by the bench. The practical effect of such an interim stay is that the accused is released or placed under judicial supervision, that any bail application pending before the lower court becomes redundant because liberty has already been granted, and that the prosecution must either seek a fresh order of custody supported by fresh material or abandon the custodial phase of the investigation. When the apex court ultimately grants relief in the form of a habeas corpus decree, the decree not only commands the immediate release of the detainee but also nullifies the operative detention order, extinguishes any pending remand, and may direct the lower court to strike down the charge sheet or to re-file it within a time-frame fixed by the bench, thereby reshaping the trajectory of the criminal proceeding. The grant of such relief also triggers a consequential impact on any parallel bail proceedings, because the Supreme Court’s order supersedes the lower court’s bail decision, rendering the bail bond moot, and obligates the prosecuting authority to reassess the necessity of any further custodial measures in light of the finding that the original detention lacked legal foundation. Finally, the Supreme Court’s final order, whether it be dismissal, interim stay, or grant of relief, becomes binding on all subordinate courts and law-enforcement agencies, and any subsequent criminal proceeding that attempts to impose custody contrary to that order may be struck down as contempt, may expose the authorities to liability for illegal confinement, and may compel the payment of compensation as prescribed by the jurisprudence on wrongful detention.