Fix whitespace damage in PPP implementation

This commit is contained in:
Marcel Holtmann 2010-03-31 10:30:54 -07:00
parent 33e11e910c
commit f87537644b
3 changed files with 4 additions and 3 deletions

View File

@ -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);
}

View File

@ -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",

View File

@ -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);
}
/*