Skip to content

Commit

Permalink
Merge remote-tracking branch 'igniterealtime/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Emiliano committed Oct 25, 2016
2 parents 9a16f68 + c379ae0 commit 9b1525d
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
* @author Gaston Dombiak
*/
public class ConsoleDebugger extends AbstractDebugger {
private final SimpleDateFormat dateFormatter = new SimpleDateFormat("hh:mm:ss aaa");
private final SimpleDateFormat dateFormatter = new SimpleDateFormat("HH:mm:ss");

public ConsoleDebugger(XMPPConnection connection, Writer writer, Reader reader) {
super(connection, writer, reader);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ private void createDebug() {
// the GUI. This is what we call "interpreted" packet data, since it's the packet
// data as Smack sees it and not as it's coming in as raw XML.
packetReaderListener = new StanzaListener() {
SimpleDateFormat dateFormatter = new SimpleDateFormat("hh:mm:ss:SS aaa");
SimpleDateFormat dateFormatter = new SimpleDateFormat("HH:mm:ss:SS");

public void processPacket(final Stanza packet) {
SwingUtilities.invokeLater(new Runnable() {
Expand All @@ -221,7 +221,7 @@ public void run() {
// Create a thread that will listen for all outgoing packets and write them to
// the GUI.
packetWriterListener = new StanzaListener() {
SimpleDateFormat dateFormatter = new SimpleDateFormat("hh:mm:ss:SS aaa");
SimpleDateFormat dateFormatter = new SimpleDateFormat("HH:mm:ss:SS");

public void processPacket(final Stanza packet) {
SwingUtilities.invokeLater(new Runnable() {
Expand Down Expand Up @@ -669,7 +669,7 @@ private void addInformationPanel() {
connPanel.add(
label,
new GridBagConstraints(0, 3, 1, 1, 0.0, 0.0, 21, 0, new Insets(0, 0, 0, 0), 0, 0));
field = new JFormattedTextField(new SimpleDateFormat("yyyy.MM.dd hh:mm:ss:SS aaa"));
field = new JFormattedTextField(new SimpleDateFormat("yyyy.MM.dd HH:mm:ss:SS"));
field.setMinimumSize(new java.awt.Dimension(150, 20));
field.setMaximumSize(new java.awt.Dimension(150, 20));
field.setValue(creationTime);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,10 @@ public synchronized void pingServerIfNecessary() {
res = pingMyServer(false);
}
catch (InterruptedException | SmackException e) {
LOGGER.log(Level.WARNING, "Exception while pinging server", e);
// Note that we log the connection here, so that it is not GC'ed between the call to isAuthenticated
// a few lines above and the usage of the connection within pingMyServer(). In order to prevent:
// https://community.igniterealtime.org/thread/59369
LOGGER.log(Level.WARNING, "Exception while pinging server of " + connection, e);
res = false;
}
// stop when we receive a pong back
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,10 @@ else if (node == null && jid != null) {
affiliation = new Affiliation(jid, affiliationType, namespace);
}
else {
throw new SmackException("Invalid affililation");
throw new SmackException("Invalid affililation. Either one of 'node' or 'jid' must be set"
+ ". Node: " + node
+ ". Jid: " + jid
+ '.');
}
return affiliation;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1515,7 +1515,7 @@ else if (presenceMap.get(key) != null) {
}

/**
* Handles roster reults as described in RFC 6121 2.1.4
* Handles Roster results as described in <a href="https://tools.ietf.org/html/rfc6121#section-2.1.4">RFC 6121 2.1.4</a>.
*/
private class RosterResultListener implements StanzaListener {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -729,6 +729,8 @@ else if (keyStoreType != null){
LOGGER.log(Level.WARNING, "Exception", e);
ks = null;
}
} else {
ks.load(null, null);
}
}

Expand Down

0 comments on commit 9b1525d

Please sign in to comment.