/*
This file is part of GNUnet.
- (C) 2011-2013 Christian Grothoff (and other contributing authors)
+ Copyright (C) 2011-2013 Christian Grothoff (and other contributing authors)
GNUnet is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
/**
* ID of a task associated with the resolution process.
*/
- GNUNET_SCHEDULER_TaskIdentifier task_id;
+ struct GNUNET_SCHEDULER_Task * task_id;
/**
* The name to resolve
{
struct GNS_ResolverHandle *rh = cls;
- rh->task_id = GNUNET_SCHEDULER_NO_TASK;
+ rh->task_id = NULL;
rh->proc (rh->proc_cls, 0, NULL);
GNS_resolver_lookup_cancel (rh);
}
const struct sockaddr_in *sa4;
const struct sockaddr_in6 *sa6;
- GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
- "Received %u bytes of DNS IP data\n",
- addrlen);
if (NULL == addr)
{
rh->std_resolve = NULL;
transmit_lookup_dns_result (rh);
return;
}
+ GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+ "Received %u bytes of DNS IP data\n",
+ addrlen);
switch (addr->sa_family)
{
case AF_INET:
rh->dns_request = NULL;
GNUNET_SCHEDULER_cancel (rh->task_id);
- rh->task_id = GNUNET_SCHEDULER_NO_TASK;
+ rh->task_id = NULL;
p = GNUNET_DNSPARSER_parse ((const char *) dns,
dns_len);
if (NULL == p)
resolver to use */
g2dc = GNUNET_new (struct Gns2DnsContext);
g2dc->ns = ns;
+
g2dc->rh = GNUNET_new (struct GNS_ResolverHandle);
g2dc->rh->authority_zone = rh->ac_tail->authority_info.gns_authority;
ip = translate_dot_plus (rh, ip);
{
struct GNS_ResolverHandle *rh = cls;
- rh->task_id = GNUNET_SCHEDULER_NO_TASK;
+ rh->task_id = NULL;
if (MAX_RECURSION < rh->loop_limiter++)
{
GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
GNUNET_free (rh->g2dc);
rh->g2dc = NULL;
}
- if (GNUNET_SCHEDULER_NO_TASK != rh->task_id)
+ if (NULL != rh->task_id)
{
GNUNET_SCHEDULER_cancel (rh->task_id);
- rh->task_id = GNUNET_SCHEDULER_NO_TASK;
+ rh->task_id = NULL;
}
if (NULL != rh->get_handle)
{