summaryrefslogtreecommitdiff
path: root/ares_query.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2004-10-06 07:50:18 +0000
committerDaniel Stenberg <daniel@haxx.se>2004-10-06 07:50:18 +0000
commit3e748f4b50224e43b916dda5de438c785bdcd49d (patch)
tree53bbfe3dae88be1fd482d3fc392cd1465214f4f3 /ares_query.c
parent47bd7d7548103c44b466fceb1dbda425ce8774bc (diff)
downloadc-ares-3e748f4b50224e43b916dda5de438c785bdcd49d.tar.gz
c-ares-3e748f4b50224e43b916dda5de438c785bdcd49d.tar.bz2
c-ares-3e748f4b50224e43b916dda5de438c785bdcd49d.zip
removed tabs and trailing whitespace from source
Diffstat (limited to 'ares_query.c')
-rw-r--r--ares_query.c44
1 files changed, 22 insertions, 22 deletions
diff --git a/ares_query.c b/ares_query.c
index 2b83265..b39dc6d 100644
--- a/ares_query.c
+++ b/ares_query.c
@@ -36,7 +36,7 @@ struct qquery {
static void qcallback(void *arg, int status, unsigned char *abuf, int alen);
void ares_query(ares_channel channel, const char *name, int dnsclass,
- int type, ares_callback callback, void *arg)
+ int type, ares_callback callback, void *arg)
{
struct qquery *qquery;
unsigned char *qbuf;
@@ -45,7 +45,7 @@ void ares_query(ares_channel channel, const char *name, int dnsclass,
/* Compose the query. */
rd = !(channel->flags & ARES_FLAG_NORECURSE);
status = ares_mkquery(name, dnsclass, type, channel->next_id, rd, &qbuf,
- &qlen);
+ &qlen);
channel->next_id++;
if (status != ARES_SUCCESS)
{
@@ -85,26 +85,26 @@ static void qcallback(void *arg, int status, unsigned char *abuf, int alen)
/* Convert errors. */
switch (rcode)
- {
- case NOERROR:
- status = (ancount > 0) ? ARES_SUCCESS : ARES_ENODATA;
- break;
- case FORMERR:
- status = ARES_EFORMERR;
- break;
- case SERVFAIL:
- status = ARES_ESERVFAIL;
- break;
- case NXDOMAIN:
- status = ARES_ENOTFOUND;
- break;
- case NOTIMP:
- status = ARES_ENOTIMP;
- break;
- case REFUSED:
- status = ARES_EREFUSED;
- break;
- }
+ {
+ case NOERROR:
+ status = (ancount > 0) ? ARES_SUCCESS : ARES_ENODATA;
+ break;
+ case FORMERR:
+ status = ARES_EFORMERR;
+ break;
+ case SERVFAIL:
+ status = ARES_ESERVFAIL;
+ break;
+ case NXDOMAIN:
+ status = ARES_ENOTFOUND;
+ break;
+ case NOTIMP:
+ status = ARES_ENOTIMP;
+ break;
+ case REFUSED:
+ status = ARES_EREFUSED;
+ break;
+ }
qquery->callback(qquery->arg, status, abuf, alen);
}
free(qquery);