Just use 0 as error for reading int keys

We fall back to default if these values are 0, so
simpler this way. Also, avoid compare of int and Null.