The official text
Old and new, side by side
Code of Criminal Procedure, 1973
Section 171 Complainant and witnesses not to be required to accompany police officer and not to be subjected to restraint
No complainant or witness on his way to any Court shall be required to accompany a police officer, or shall be subjected to unnecessary restraint or inconvenience, or required to give any security for his appearance other than his own bond:
Provided that, if any complainant or witness refuses to attend or to execute a bond as directed in section 170, the officer in charge of the police station may forward him in custody to the Magistrate, who may detain him in custody until he executes such bond, or until the hearing of the case is completed.
Bharatiya Nagarik Suraksha Sanhita, 2023
Section 191 Complainant and witnesses not to be required to accompany police officer and not to be subject to restraint
No complainant or witness on his way to any Court shall be required to accompany a police officer, or shall be subjected to unnecessary restraint or inconvenience, or required to give any security for his appearance other than his own bond:
Provided that if any complainant or witness refuses to attend or to execute a bond as directed in section 190, the officer in charge of the police station may forward him in custody to the Magistrate, who may detain him in custody until he executes such bond, or until the hearing of the case is completed.
The texts are India Code’s. The amendment markers and footnotes of the official print are left out, so the old section reads as it stood when it was repealed; State amendments are not shown. The PDFs linked below carry the full history.