projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
27894d5
)
Mention the client host name or address in the logs
author
Art Cancro
<ajc@citadel.org>
Mon, 13 Sep 2010 03:02:39 +0000
(23:02 -0400)
committer
Art Cancro
<ajc@citadel.org>
Mon, 13 Sep 2010 03:02:39 +0000
(23:02 -0400)
webcit/locate_host.c
patch
|
blob
|
history
diff --git
a/webcit/locate_host.c
b/webcit/locate_host.c
index 8f1a769555867c39899f785f6d23c80dfa8689b5..b3346e4c7d6cf23835993e9e6ea0bce935d60adb 100644
(file)
--- a/
webcit/locate_host.c
+++ b/
webcit/locate_host.c
@@
-19,6
+19,7
@@
*/
#include "webcit.h"
+#include "webserver.h"
/*
* IPv4/IPv6 locate_host()
@@
-32,4
+33,5
@@
void locate_host(StrBuf *tbuf, int client_socket)
getpeername(client_socket, (struct sockaddr *)&clientaddr, &addrlen);
getnameinfo((struct sockaddr *)&clientaddr, addrlen, clienthost, sizeof(clienthost), NULL, 0, 0);
StrBufAppendBufPlain(tbuf, clienthost, -1, 0);
+ lprintf(9, "Client is at %s\n", clienthost);
}