if (ats_count == 0)
return;
- for (i=0;i<ats_count;i++)
+ for (i = 0; i < ats_count; i++)
{
- for (j=0;j<n->ats_count;j++)
+ for (j=0;j < n->ats_count; j++)
{
if (n->ats[j].type == ats[i].type)
{
break;
}
}
- if (j == n->ats_count)
- GNUNET_array_append (n->ats,
- n->ats_count,
- *ats);
+ if (j == n->ats_count)
+ {
+ GNUNET_array_append (n->ats,
+ n->ats_count,
+ ats[i]);
+ }
}
}
const void *m, size_t msize)
{
size_t size = msize + sizeof (struct NotifyTrafficMessage) +
- (sender->ats_count+1) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
+ (sender->ats_count) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
char buf[size];
struct NotifyTrafficMessage *ntm;
struct GNUNET_TRANSPORT_ATS_Information *ats;
sender->ats_count,
0);
size = msize + sizeof (struct NotifyTrafficMessage) +
- (sender->ats_count+1) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
+ (sender->ats_count) * sizeof (struct GNUNET_TRANSPORT_ATS_Information);
}
#if DEBUG_CORE
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,