<commit_before>#include "cent.h"
#include <stdio.h>
#include <stdlib.h>
#include "os_generic.h"

void MyClientCentCB( struct CentConnection * s, struct Cent * tn, void * id )
{
	float * values = (float*)tn->data;
	printf( "CLIENT: %s %p %f %f\n", tn->name, id, values[0], values[1] );
}


void * CentClientThread( void * v )
{
	struct Cent * c;
	int q;
	struct CentConnection * conn = CentConnect( "127.0.0.1", 8553 );

	CentClientAddCB( conn, "*i", MyClientCentCB, (void*)1 );
	CentClientAddCB( conn, "/*/mark", MyClientCentCB, 0 );

	while(1)
	{
		float * fvs2 = malloc( 8 );
		fvs2[0] = 5;
		fvs2[1] = q++;
		c = CreateCent( "/fromclient/test", CENTFLAGS_OK, CENTCODES_FLOATS, 8, (void*)fvs2 );
		SendEventClient( conn, c, 1 );

		OGUSleep(250000);
	}
}


int main()
{
	og_thread_t client;

	client = OGCreateThread( CentClientThread, 0 );

	while(1)
	{
		OGSleep(1);
	}
}

<commit_msg>Making the client listen for locations for testing purposes<commit_after>#include "cent.h"
#include <stdio.h>
#include <stdlib.h>
#include "os_generic.h"

void MyClientCentCB( struct CentConnection * s, struct Cent * tn, void * id )
{
	float * values = (float*)tn->data;
	printf( "CLIENT: %s %p %f %f\n", tn->name, id, values[0], values[1] );
}


void * CentClientThread( void * v )
{
	struct Cent * c;
	int q;
	struct CentConnection * conn = CentConnect( "127.0.0.1", 8553 );

	CentClientAddCB( conn, "*loc", MyClientCentCB, (void*)1 );
	CentClientAddCB( conn, "/*/mark", MyClientCentCB, 0 );

	while(1)
	{
		float * fvs2 = malloc( 8 );
		fvs2[0] = 5;
		fvs2[1] = q++;
		c = CreateCent( "/fromclient/test", CENTFLAGS_OK, CENTCODES_FLOATS, 8, (void*)fvs2 );
		SendEventClient( conn, c, 1 );

		OGUSleep(250000);
	}
}


int main()
{
	og_thread_t client;

	client = OGCreateThread( CentClientThread, 0 );

	while(1)
	{
		OGSleep(1);
	}
}


{'fraction_non_alphanumeric': 0.1741511500547645, 'fraction_numerical': 0.03723986856516977, 'mean_word_length': 4.033057851239669, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5596915', 'n_tokens_mistral': 808, 'n_tokens_neox': 747, 'n_words': 182}