tested) to the list of emacs versions that need comint-input-ring-index
"hack".
Given that it's been almost 15 years since the date in the preceding
comment I wonder if there should be a better way to handle this, but
for now just use brute force.
Makes comint history navigation work as expected.