Various improvements to cat.asm

- Change buflen to a defined quantity so it only needs to be changed in
  one place
- Create an _exit procedure that we can call with different exit values
- Make sure that some of the places we might want to exit set the
  correct exit value