Switch status code set/get to integer fixes #881

Indentation still wrong.