summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvan Prodromou <evan@prodromou.name>2008-07-16 02:19:33 -0400
committerEvan Prodromou <evan@prodromou.name>2008-07-16 02:19:33 -0400
commitdd96edde7720d470772d1749ab2c3d18fbd2df33 (patch)
treecd3f3f5e481cd1080c6085bfe717c3e89bc3bdfa
parente1711bb0cf36a28c3c8b9047c0748432348e5ccb (diff)
add some warnings and stuff
darcs-hash:20080716061933-84dde-7bb5f28c9263782bc0535cd8303a9fcad3820134.gz
-rw-r--r--lib/jabber.php11
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/jabber.php b/lib/jabber.php
index cb30fc023..a044f9c1b 100644
--- a/lib/jabber.php
+++ b/lib/jabber.php
@@ -37,8 +37,11 @@ class Laconica_XMPP extends XMPPHP_XMPP {
$out .= "<body>$body</body>";
if($payload) $out .= $payload;
$out .= "</message>";
-
+
+ $cnt = strlen($out);
+ common_log(LOG_DEBUG, 'Sending $cnt chars to $to');
$this->send($out);
+ common_log(LOG_DEBUG, 'Done.');
}
}
@@ -218,6 +221,9 @@ function jabber_broadcast_notice($notice) {
$sent_to[$user->id] = true;
} else {
# XXX: Not sure, but I think that's the right thing to do
+ common_log(LOG_WARNING,
+ 'Sending reply notice ' . $notice->id . ' to ' . $user->jabber . ' FAILED, cancelling.',
+ __FILE__);
return false;
}
}
@@ -240,6 +246,9 @@ function jabber_broadcast_notice($notice) {
$sent_to[$user->id] = true;
} else {
# XXX: Not sure, but I think that's the right thing to do
+ common_log(LOG_WARNING,
+ 'Sending notice ' . $notice->id . ' to ' . $user->jabber . ' FAILED, cancelling.',
+ __FILE__);
return false;
}
}