A couple of fixes for signed ints