When muc#roominfo_subject contains no value then Smack will fail with a NPE.
This issue is not fixed, the patch does not work correctly.
This is still an issue in v3.1.0. RoomInfo ctor throws an NPE when connecting to an ejabberd server.
The code was changed from
this.subject = form.getField("muc#roominfo_subject").getValues().next();
to
Iterator<String> values = form.getField("muc#roominfo_subject").getValues();
if (values.hasNext()) {
this.subject = values.next();
}
else {
this.subject = "";
}
The correct fix is:
final FormField subjField = form.getField("muc#roominfo_subject");
this.subject = subjField == null ? "" : subjField.getValues().next();
Note that description has potentially the same problem.
According to a community report this has to reopen
Can you take a look into it and review, if we need that for 2.6.0 RC2 or 2.6.0 final?
All three form fields accessed had the same issue and are now fixed.