aboutsummaryrefslogtreecommitdiff
path: root/src/espik_net.c
diff options
context:
space:
mode:
authorbeber <beber>2005-12-02 10:56:29 +0000
committerbeber <beber>2005-12-02 10:56:29 +0000
commite81fbef07d723955738ab5a6ddb349a72a18f6ff (patch)
tree790ea49f400819a6fe26d78b245d772c6aceb165 /src/espik_net.c
parent#e.fr (diff)
downloadespik-e81fbef07d723955738ab5a6ddb349a72a18f6ff.tar.xz
Some work on debug
Diffstat (limited to 'src/espik_net.c')
-rw-r--r--src/espik_net.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/espik_net.c b/src/espik_net.c
index ee271c1..058f153 100644
--- a/src/espik_net.c
+++ b/src/espik_net.c
@@ -15,6 +15,8 @@
typedef int (*Handler_Func) (void* data, int ev_type, void* ev);
+static int ret; /* For debug */
+
Ecore_Con_Server* con_sock;
void espik_con_init (t_info serv_info)
@@ -24,7 +26,7 @@ void espik_con_init (t_info serv_info)
nb_launch = ecore_con_init ();
#if _ESPIK_DEBUG_
- printf ("espik_con_init: nb_launch = %d\n", nb_launch);
+/* printf ("espik_con_init: nb_launch = %d\n", nb_launch); */
#endif
con_sock = ecore_con_server_connect (ECORE_CON_REMOTE_SYSTEM,
@@ -38,7 +40,7 @@ void espik_con_init (t_info serv_info)
if (! (ecore_event_handler_add (ECORE_CON_EVENT_SERVER_DATA,
(Handler_Func) server_data, NULL)))
{
- fprintf (stderr, "ecore_event_handler_add failed at espik_con_init\n");
+ fprintf (stderr, "ecore_event_handler_add failed at %s\n", __FUNCTION__);
exit (-1);
}
}
@@ -46,14 +48,14 @@ void espik_con_init (t_info serv_info)
void espik_con_shutdown ()
{
#if _ESPIK_DEBUG_
- printf ("> espik_con_shutdown\n");
+/* printf ("> espik_con_shutdown\n"); */
#endif
ecore_con_server_del (con_sock);
ecore_con_shutdown ();
#if _ESPIK_DEBUG_
- printf ("< espik_con_shutdown\n");
+/* printf ("< espik_con_shutdown\n"); */
#endif
/* ecore_main_loop_quit (); */
}
@@ -62,7 +64,6 @@ void espik_raw_send (char *msg)
{
int len;
char* out;
- int ret; /* FIXME: DEL THAT ! */
len = strlen (msg) + 3;
@@ -71,7 +72,7 @@ void espik_raw_send (char *msg)
snprintf (out, len, "%s\r\n", msg);
#if _ESPIK_DEBUG_
- printf ("espik_raw_send:\nmsg: %s\nout: %s\n", msg, out);
+/* printf ("espik_raw_send:\nmsg: %s\nout: %s\n", msg, out); */
#endif
/*
printf ("out[len-3]: 0x%X\n", out[len - 3]);
@@ -82,7 +83,7 @@ void espik_raw_send (char *msg)
ret = ecore_con_server_send (con_sock, out, strlen (out));
#if _ESPIK_DEBUG_
- printf ("ecore_con_server_send: %d\n", ret);
+/* printf ("ecore_con_server_send: %d\n", ret); */
#endif
free (out);