<commit_before>#include <stdio.h>
#include <accessory.h>

// This is a echo server. It will send anything back you send to it.
// You can connect to this accessory using bluetooth or usb.
// There is no associated Android application to test this, you will have to write that yourself.

// Compile this program using:
// gcc example.c -o example $(pkg-config --libs --cflags libandroidaccessory-1.0)

int main (int argc, char *argv[])
{
    Accessory* accessory;
    AapConnection* con;
    int connected = 1;
    
    const char* const uuids[] = {
        /* You should generate your own uuid using uuidgen, dont copy paste this */
		"db0d662d-40cf-4995-9849-6dc604563e10",
		NULL
	};
	
	accessory = initAccessory(
		"Echo server company",
		"Echo server",
		"This echo server will send anything back you send it",
		uuids,
		"1.0",
		// I diddent actually test if blueterm can communicate to libAndroidAccessory
		"https://play.google.com/store/apps/details?id=es.pymasde.blueterm",
		"5890699");
	
	printf("Waiting for new connection\n");
	con = getNextAndroidConnection(accessory);
	printf("New connection accepted\n");
	while(connected)
	{
	    int read;
	    char buffer[1024];
	    
	    read = readAccessory(con, buffer, sizeof(buffer));
	    if(read < 0)
	    {
	        connected = 0;
	        break;
	    }
	    
	    printf("Read %i bytes\n", read);
	    
	    // Note: I use writeAllAccessory() instead of writeAccessory() here.
	    // This function guarantees to write everything or return a error.
	    if(writeAllAccessory(con, buffer, read))
	    {
	        connected = 0;
	        break;
	    }
	}
	printf("Connection ended.\n");
	
	closeAndroidConnection(con);
	deInitaccessory(accessory);
}

<commit_msg>MISC: converted tabs to spaces<commit_after>#include <stdio.h>
#include <accessory.h>

// This is a echo server. It will send anything back you send to it.
// You can connect to this accessory using bluetooth or usb.
// There is no associated Android application to test this, you will have to write that yourself.

// Compile this program using:
// gcc example.c -o example $(pkg-config --libs --cflags libandroidaccessory-1.0)

int main (int argc, char *argv[])
{
    Accessory* accessory;
    AapConnection* con;
    int connected = 1;
    
    const char* const uuids[] = {
        /* You should generate your own uuid using uuidgen, dont copy paste this */
        "db0d662d-40cf-4995-9849-6dc604563e10",
        NULL
    };
    
    accessory = initAccessory(
        "Echo server company",
        "Echo server",
        "This echo server will send anything back you send it",
        uuids,
        "1.0",
        // I diddent actually test if blueterm can communicate to libAndroidAccessory
        "https://play.google.com/store/apps/details?id=es.pymasde.blueterm",
        "5890699");
    
    printf("Waiting for new connection\n");
    con = getNextAndroidConnection(accessory);
    printf("New connection accepted\n");
    while(connected)
    {
        int read;
        char buffer[1024];
        
        read = readAccessory(con, buffer, sizeof(buffer));
        if(read < 0)
        {
            connected = 0;
            break;
        }
        
        printf("Read %i bytes\n", read);
        
        // Note: I use writeAllAccessory() instead of writeAccessory() here.
        // This function guarantees to write everything or return a error.
        if(writeAllAccessory(con, buffer, read))
        {
            connected = 0;
            break;
        }
    }
    printf("Connection ended.\n");
    
    closeAndroidConnection(con);
    deInitaccessory(accessory);
}


{'fraction_non_alphanumeric': 0.10617760617760617, 'fraction_numerical': 0.023166023166023165, 'mean_word_length': 2.480806142034549, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, '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': '6946670', 'n_tokens_mistral': 1177, 'n_tokens_neox': 1079, 'n_words': 350}