[QFJ-320] Negative TimeZoneOffset newIncorrectDataException Created: 01/Jul/08  Updated: 22/Jul/14  Resolved: 22/Jul/14

Status: Closed
Project: QuickFIX/J
Component/s: Engine
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Default
Reporter: Zana Assignee: Unassigned
Resolution: Duplicate Votes: 0
Labels: None


 Description   

When trying to retrieve a negative timezone, I get an exception quickfix.FieldMap.newIncorrectDataException(FieldMap.java:410).

It seems that it is caused by the following code in IntConverter.java, it expects only digits.
public static int convert(String value) throws FieldConvertError {
try {
for (int i = 0; i < value.length(); i++) {
if (!Character.isDigit(value.charAt))

{ throw new NumberFormatException(); }

return Integer.parseInt(value);
...

The code I am using is as follows:

TimezoneOffset timezoneOffset = new TimezoneOffset();
try {
noMDEntries.get(timezoneOffset);
} catch(FieldNotFound e) {
//field is optional
}



 Comments   
Comment by Steve Bate [ 01/Jul/08 ]

Thanks for the report. This has already been fixed in the trunk.

Generated at Sat May 04 13:19:43 UTC 2024 using JIRA 7.5.2#75007-sha1:9f5725bb824792b3230a5d8716f0c13e296a3cae.