#include "gnunet_util_lib.h"
#include "gnunet_statistics_service.h"
#include "gnunet-service-ats_addresses.h"
-
+#include "gnunet-service-ats_normalization.h"
#include "gnunet_ats_service.h"
#include "gnunet_ats_plugin.h"
#include "test_ats_api_common.h"
bandwidth_changed_cb (void *cls,
struct ATS_Address *address)
{
- if ( (0 == ntohl (address->assigned_bw_out.value__)) &&
- (0 == ntohl (address->assigned_bw_in.value__)) )
+ if ( (0 == address->assigned_bw_out) && (0 == address->assigned_bw_in) )
return;
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Bandwidth changed addresses %s %p to %u Bps out / %u Bps in\n",
GNUNET_i2s (&address->peer),
address,
- (unsigned int) ntohl (address->assigned_bw_out.value__),
- (unsigned int) ntohl (address->assigned_bw_in.value__));
+ address->assigned_bw_out,
+ address->assigned_bw_in);
if (GNUNET_YES == ph.bulk_running)
GNUNET_break (0);
return;
}
else
{
- GNUNET_asprintf (&data_str, "%s;", data_tmp);
+ GNUNET_asprintf (&data_upd_str, "%s;", data_upd_tmp);
}
GNUNET_free (data_upd_tmp);
GNUNET_asprintf (&data_upd_str, "%s\n", data_upd_tmp);
GNUNET_free (data_upd_tmp);
- fprintf (stderr, "Result updated solution: %s\n", data_upd_str);
+ fprintf (stderr, "Result updated solution: `%s'\n", data_upd_str);
if (GNUNET_SYSERR == GNUNET_DISK_file_write (f_update, data_upd_str, strlen(data_upd_str)))
GNUNET_break (0);
GNUNET_free (data_upd_str);