Example #1
0
void GSendStr(const char *buf)
{
    int len = buf ? strlen(buf) + 1 : 0;
    GDebug("Sending string %'s to %s\n", buf, who);
    GWrite(&len, sizeof(len));
    GWrite(buf, len);
}
Example #2
0
void
GSendArr( int len, const char *buf )
{
    GDebug( "Sending array %02[:*hhx to %s\n", len, buf, who );
    GWrite( &len, sizeof(len) );
    GWrite( buf, len );
}
Example #3
0
static void
GSendNStr( const char *buf, int len )
{
	int tlen = len + 1;
	GWrite( &tlen, sizeof(tlen) );
	GWrite( buf, len );
	GWrite( "", 1 );
}
Example #4
0
static void
GSendStr( const char *buf )
{
	if (buf) {
		int len = strlen( buf ) + 1;
		GWrite( &len, sizeof(len) );
		GWrite( buf, len );
	} else
		GWrite( &buf, sizeof(int));
}
Example #5
0
bool Greeter::GSendArr(int len, const char *buf)
{
    return GWrite(&len, sizeof(len)) && GWrite (buf, len);
}
Example #6
0
bool Greeter::GSendStr(const char *buf)
{
    int len = buf ? ::strlen (buf) + 1 : 0;
    return GWrite(&len, sizeof(len)) && GWrite (buf, len);
}
Example #7
0
bool Greeter::GSendInt(int val)
{
    return GWrite(&val, sizeof(val));
}
Example #8
0
static void
GSendArr( int len, const char *data )
{
	GWrite( &len, sizeof(len) );
	GWrite( data, len );
}
Example #9
0
static void
GSendInt( int val )
{
	GWrite( &val, sizeof(val) );
}
Example #10
0
void GSendInt(int val)
{
    GDebug("Sending int %d (%#x) to %s\n", val, val, who);
    GWrite(&val, sizeof(val));
}
Example #11
0
bool KCheckPass::GSendArr(int len, const char *buf)
{
    return GWrite(&len, sizeof(len)) && GWrite (buf, len);
}
Example #12
0
bool KCheckPass::GSendInt(int val)
{
    return GWrite(&val, sizeof(val));
}