If you want help, you'll have to provide an SSCCE that demonstrates the problem- in your case, a main method containing a single printf statement with the values that cause the Exception.