<commit_before>#include <E_Nm.h>
#include <Ecore_Data.h>

#define E_NM_DEVICE_TYPE_WIRED 1
#define E_NM_DEVICE_TYPE_WIRELESS 2

typedef struct NM_Manager NM_Manager;
struct NM_Manager
{
  E_NM_Context *ctx;
  Ecore_List *devices;
};

typedef struct NM_Device NM_Device;
struct NM_Device
{
  int type;
  char *object_path;
  char *device_name;
};

void
cb_manager_get_name(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got name:\n");
   printf("  %s\n", (char *)reply);
}

void
cb_manager_get_type(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got type:\n");
   printf("  %i (0 == unknown, 1 == ethernet, 2 == wireless)\n", (int)(*((dbus_int32_t *)reply)));
}

void
cb_manager_get_hal_udi(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got hal udi:\n");
   printf("  %s\n", (char *)reply);
}

void
cb_manager_get_ip4_address(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got ip4_address:\n");
   printf("  %i.%i.%i.%i\n", 
	  (int)(((*((dbus_int32_t *)reply))      ) & 0xff),
	  (int)(((*((dbus_int32_t *)reply)) >> 8 ) & 0xff),
	  (int)(((*((dbus_int32_t *)reply)) >> 16) & 0xff),
	  (int)(((*((dbus_int32_t *)reply)) >> 24) & 0xff)
	  );
}

void
cb_manager_get_link_active(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got active:\n");
   printf("  %i\n", (int)(*((dbus_bool_t *)reply)));
}

void
cb_manager_wireless_get_strength(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got Wireless Strength:\n");
   printf("  %i\n", (int)(*((dbus_int32_t *)reply)));
}

void
cb_manager_wireless_get_active_network(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got Wireless Active Network:\n");
   printf("  %s\n", (char *)reply);
}

void
cb_manager_wireless_get_networks(void *data, void *reply, DBusError *err)
{
   NM_Manager *app = data;
   Ecore_List *networks;
   const char *net;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;<commit_msg>Remove unused variables.<commit_after>#include <E_Nm.h>
#include <Ecore_Data.h>

#define E_NM_DEVICE_TYPE_WIRED 1
#define E_NM_DEVICE_TYPE_WIRELESS 2

typedef struct NM_Manager NM_Manager;
struct NM_Manager
{
  E_NM_Context *ctx;
  Ecore_List *devices;
};

typedef struct NM_Device NM_Device;
struct NM_Device
{
  int type;
  char *object_path;
  char *device_name;
};

void
cb_manager_get_name(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got name:\n");
   printf("  %s\n", (char *)reply);
}

void
cb_manager_get_type(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got type:\n");
   printf("  %i (0 == unknown, 1 == ethernet, 2 == wireless)\n", (int)(*((dbus_int32_t *)reply)));
}

void
cb_manager_get_hal_udi(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got hal udi:\n");
   printf("  %s\n", (char *)reply);
}

void
cb_manager_get_ip4_address(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got ip4_address:\n");
   printf("  %i.%i.%i.%i\n", 
	  (int)(((*((dbus_int32_t *)reply))      ) & 0xff),
	  (int)(((*((dbus_int32_t *)reply)) >> 8 ) & 0xff),
	  (int)(((*((dbus_int32_t *)reply)) >> 16) & 0xff),
	  (int)(((*((dbus_int32_t *)reply)) >> 24) & 0xff)
	  );
}

void
cb_manager_get_link_active(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got active:\n");
   printf("  %i\n", (int)(*((dbus_bool_t *)reply)));
}

void
cb_manager_wireless_get_strength(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got Wireless Strength:\n");
   printf("  %i\n", (int)(*((dbus_int32_t *)reply)));
}

void
cb_manager_wireless_get_active_network(void *data, void *reply, DBusError *err)
{
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
     }
   printf("Got Wireless Active Network:\n");
   printf("  %s\n", (char *)reply);
}

void
cb_manager_wireless_get_networks(void *data, void *reply, DBusError *err)
{
   Ecore_List *networks;
   const char *net;
   
   if (dbus_error_is_set(err))
     {
	//XXX
	printf("Error: %s - %s\n" ,err->name, err->message);
	return;
{'fraction_non_alphanumeric': 0.19063428271885374, 'fraction_numerical': 0.009785077756421458, 'mean_word_length': 3.6235864297253637, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 51, 'https://': 0, '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': '1010434', 'n_tokens_mistral': 2513, 'n_tokens_neox': 2383, 'n_words': 485}