The GeoLocation constructor sets this to null incase the accuracy field is set
Smack/GeoLocation.java at master · igniterealtime/Smack · GitHub
Issues
The parser throws an exception when parsing a geolocation message due to the error field being null
Why does the parser need all the fields to be defined. There are so many fields of type double and all need to be defined. The GeoLocation builder doesn’t mandate all the fields, but the parser does. Ideally parser should parse a GeoLocation message with any of the fields set, and should be tolerant of missing fields
These nulls are being parsed as double by parser and there is a parse failure when received. Maybe the parser can ignore these invalid fields and proceed parsing further
Even when the accuracy, alt, bearing, error, lat, lon, speed are all set, the error field is being set to null (if accuracy exists) in the GeoLocation constructor. So the xml message will have null for error field. And parsing fails.