summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2010-03-31 10:30:54 -0700
committerMarcel Holtmann <marcel@holtmann.org>2010-03-31 10:30:54 -0700
commitf87537644bfca99cc8da6c23f9380976261ebbcd (patch)
tree3729aa1739d79e5c6ec3766f4bf3cb9d918d0558
parent33e11e910c066da91bebf796bb1aaf96d65a388f (diff)
downloadofono-f87537644bfca99cc8da6c23f9380976261ebbcd.tar.bz2
Fix whitespace damage in PPP implementation
-rw-r--r--gatchat/ppp.c4
-rw-r--r--gatchat/ppp_cp.c1
-rw-r--r--gatchat/ppp_net.c2
3 files changed, 4 insertions, 3 deletions
diff --git a/gatchat/ppp.c b/gatchat/ppp.c
index f93b52d9..7755791c 100644
--- a/gatchat/ppp.c
+++ b/gatchat/ppp.c
@@ -164,7 +164,7 @@ static guint8 *ppp_encode(GAtPPP *ppp, guint8 *data, int len,
}
/* add FCS */
- fcs ^= 0xffff; /* complement */
+ fcs ^= 0xffff; /* complement */
ppp_put(ppp, frame, &pos, (guint8)(fcs & 0x00ff), lcp);
ppp_put(ppp, frame, &pos, (guint8)((fcs >> 8) & 0x00ff), lcp);
@@ -324,7 +324,7 @@ void ppp_transmit(GAtPPP *ppp, guint8 *packet, guint infolen)
* we won't block, or allow ourselves to block here?
*/
status = g_io_channel_write_chars(ppp->modem, (gchar *) frame,
- framelen, &bytes_written, &error);
+ framelen, &bytes_written, &error);
g_free(frame);
}
diff --git a/gatchat/ppp_cp.c b/gatchat/ppp_cp.c
index ac1a37d1..dbddb954 100644
--- a/gatchat/ppp_cp.c
+++ b/gatchat/ppp_cp.c
@@ -34,6 +34,7 @@
#include "gatppp.h"
#include "ppp.h"
+#define DEBUG
#ifdef DEBUG
static const char *pppcp_state_strings[] =
{"INITIAL", "STARTING", "CLOSED", "STOPPED", "CLOSING", "STOPPING",
diff --git a/gatchat/ppp_net.c b/gatchat/ppp_net.c
index 4b459ade..bc9ec171 100644
--- a/gatchat/ppp_net.c
+++ b/gatchat/ppp_net.c
@@ -75,7 +75,7 @@ static void ip_process_packet(gpointer priv, guint8 *packet)
/* find the length of the packet to transmit */
len = get_host_short(&packet[2]);
status = g_io_channel_write_chars(data->channel, (gchar *) packet,
- len, &bytes_written, &error);
+ len, &bytes_written, &error);
}
/*