projects
/
umurmur.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
44404c5
)
Fixed server crash when setting Access token while connected.
author
fatbob313
<martin@fatbob.nu>
Sun, 7 Mar 2010 20:49:15 +0000
(20:49 +0000)
committer
fatbob313
<martin@fatbob.nu>
Sun, 7 Mar 2010 20:49:15 +0000
(20:49 +0000)
src/messagehandler.c
patch
|
blob
|
history
diff --git
a/src/messagehandler.c
b/src/messagehandler.c
index ae613dafb6d7be3fa30ba4caab9e3efcd57863d2..ba76ed68520befedf1c9e0088055a80e2938b5c4 100644
(file)
--- a/
src/messagehandler.c
+++ b/
src/messagehandler.c
@@
-79,9
+79,15
@@
void Mh_handle_message(client_t *client, message_t *msg)
}
switch (msg->messageType) {
case Authenticate:
}
switch (msg->messageType) {
case Authenticate:
-
Log_debug("Authenticate message received");
Log_debug("Authenticate message received");
- Log_debug("Username: %s", msg->payload.authenticate->username);
+
+ if (IS_AUTH(client) || !msg->payload.authenticate->username) {
+ /* Authenticate message might be sent when a token is set by the user.*/
+ if (msg->payload.authenticate->n_tokens > 0) {
+ Log_debug("Tokens in auth message from %s", client->username);
+ }
+ break;
+ }
client->authenticated = true;
client->authenticated = true;