summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillaume Friloux <kuri@friloux.me>2014-04-19 23:38:04 +0200
committerGuillaume Friloux <kuri@friloux.me>2014-04-19 23:38:04 +0200
commit6afedf5eab36225741634221fbf7754226fea920 (patch)
tree50816bcf1e2db82a9a30ac9eb8a27797f1925f03
parentb7d72f9d68d04fb76366f1aa68e56317e3779609 (diff)
Get some info on finger packets
-rw-r--r--src/lib/fingered_event.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/lib/fingered_event.c b/src/lib/fingered_event.c
index cd94f60..1953c21 100644
--- a/src/lib/fingered_event.c
+++ b/src/lib/fingered_event.c
@@ -75,6 +75,14 @@ fingered_event_data(void *data,
75 f = data; 75 f = data;
76 event = ev; 76 event = ev;
77 77
78 snprintf(fmt, sizeof(fmt),
79 "Received %i bytes from client:\n"
80 ">>>>>\n"
81 "%%.%is\n"
82 ">>>>>\n",
83 event->size, event->size);
84 printf(fmt, event->data);
85
78 n = memchr(event->data, '\n', event->size); 86 n = memchr(event->data, '\n', event->size);
79 if ((!n) || (event->size == 1) || (*(n-1) != '\r')) 87 if ((!n) || (event->size == 1) || (*(n-1) != '\r'))
80 { 88 {
@@ -84,13 +92,6 @@ fingered_event_data(void *data,
84 return EINA_TRUE; 92 return EINA_TRUE;
85 } 93 }
86 94
87 snprintf(fmt, sizeof(fmt),
88 "Received %i bytes from client:\n"
89 ">>>>>\n"
90 "%%.%is\n"
91 ">>>>>\n",
92 event->size, event->size);
93 printf(fmt, event->data);
94 95
95 for (p = event->data; (n - p) > 1; p++) 96 for (p = event->data; (n - p) > 1; p++)
96 { 97 {