changed unsigned numeric values to signed numeric values and changes exception handling