Fix path completion when UTF8 char is occurring before match characters.

Small fix to #8838 so completion works again on: `"β $dir_space\\space"`, @tkelman, @ivarne
My solution is faster.   Why don't you want to use `nextind(s,endof(s)) - offset + 1`?