Changeset 30053 in osm for applications/editors/josm/plugins/tracer2/src
- Timestamp:
- 2013-11-17T10:21:17+01:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/tracer2/src/org/openstreetmap/josm/plugins/tracer2/server/GetVersion.java
r30047 r30053 23 23 public int m_nVersionMajor = -1; 24 24 public int m_nVersionMinor = -1; 25 public int m_nVersionBuild = -1; 26 public int m_nVersionRevision = -1; 25 27 26 28 /** … … 46 48 47 49 String[] astrParts = strResponse.split(":"); 48 if (astrParts.length !=2) {50 if (astrParts.length < 2) { 49 51 return; 50 52 } 51 i ntnMajor = Integer.parseInt(astrParts[0]);52 i ntnMinor = Integer.parseInt(astrParts[1]);53 m_nVersionMajor = nMajor;54 m_nVersionMinor = nMinor;53 if (astrParts.length > 0) m_nVersionMajor = Integer.parseInt(astrParts[0]); 54 if (astrParts.length > 1) m_nVersionMinor = Integer.parseInt(astrParts[1]); 55 if (astrParts.length > 2) m_nVersionBuild = Integer.parseInt(astrParts[2]); 56 if (astrParts.length > 3) m_nVersionMinor = Integer.parseInt(astrParts[3]); 55 57 } catch (Exception e) { 56 58 }
Note:
See TracChangeset
for help on using the changeset viewer.