Well then change the BCS to BCC, with the branch location being the INX instruction. So if the carry flag is clear, you skip over the increment to B. But if there was an overflow and the carry flag is set, then the BCC condition will fail, and the branch will not take place, so the increment will be executed.
There is another way to do this, which is to use the ADC instruction - add with carry - and not use the conditional branch. So it would read:
There:
ADDB 0,X
ADCA #0
INX
- etc -
You add a zero to A each time, which does nothing, but if the carry flag is set, it will add that too.