ARES_PARSE_AAAA_REPLY(3) Library Functions Manual ARES_PARSE_AAAA_REPLY(3)NAME
ares_parse_aaaa_reply - Parse a reply to a DNS query of type AAAA
SYNOPSIS
#include <ares.h>
int ares_parse_aaaa_reply(const unsigned char *abuf, int alen,
struct hostent **host,
struct ares_addr6ttl *addrttls, int *naddrttls);
DESCRIPTION
The ares_parse_aaaa_reply function parses the response to a query of type AAAA into a struct hostent and/or an array of struct
ares_addr6ttl. The parameters abuf and alen give the contents of the response. The result is stored in allocated memory and a pointer to
it stored into the variable pointed to by host, if host is nonnull. It is the caller's responsibility to free the resulting host structure
using ares_free_hostent(3) when it is no longer needed.
If addrttls and naddrttls are both nonnull, then up to *naddrttls struct ares_addr6ttl records are stored in the array pointed to by addrt-
tls, and then *naddrttls is set to the number of records so stored. Note that the memory for these records is supplied by the caller.
RETURN VALUES
ares_parse_aaaa_reply can return any of the following values:
ARES_SUCCESS The response was successfully parsed.
ARES_EBADRESP The response was malformatted.
ARES_ENODATA The response did not contain an answer to the query.
ARES_ENOMEM Memory was exhausted.
SEE ALSO ares_gethostbyname(3), ares_free_hostent(3)AUTHOR
Dominick Meglio
Copyright 2005 by Dominick Meglio.
20 Nov 2009 ARES_PARSE_AAAA_REPLY(3)
Check Out this Related Man Page
ARES_PARSE_A_REPLY(3) Library Functions Manual ARES_PARSE_A_REPLY(3)NAME
ares_parse_a_reply - Parse a reply to a DNS query of type A
SYNOPSIS
#include <ares.h>
int ares_parse_a_reply(const unsigned char *abuf, int alen,
struct hostent **host,
struct ares_addrttl *addrttls, int *naddrttls);
DESCRIPTION
The ares_parse_a_reply function parses the response to a query of type A into a struct hostent and/or an array of struct ares_addrttls.
The parameters abuf and alen give the contents of the response. The result is stored in allocated memory and a pointer to it stored into
the variable pointed to by host, if host is nonnull. It is the caller's responsibility to free the resulting host structure using
ares_free_hostent(3) when it is no longer needed.
If addrttls and naddrttls are both nonnull, then up to *naddrttls struct ares_addrttl records are stored in the array pointed to by addrt-
tls, and then *naddrttls is set to the number of records so stored. Note that the memory for these records is supplied by the caller.
RETURN VALUES
ares_parse_a_reply can return any of the following values:
ARES_SUCCESS The response was successfully parsed.
ARES_EBADRESP The response was malformatted.
ARES_ENODATA The response did not contain an answer to the query.
ARES_ENOMEM Memory was exhausted.
SEE ALSO ares_gethostbyname(3), ares_free_hostent(3)AUTHOR
Greg Hudson, MIT Information Systems
Copyright 1998 by the Massachusetts Institute of Technology.
25 July 1998 ARES_PARSE_A_REPLY(3)
Dear all ,
I have a file whose content has the following format:
jboss.web:type=ThreadPool,name=AAAA
jboss.web:type=ThreadPool,name=BBBB
How can I parse this file to get the value of the name of each line (AAAA , BBBB) and store the result to an array ? (array = AAAA , array = BBBB).... (4 Replies)
Hello All,
I have a file with thousands of records:
eg:
|000222|123456987|||||||AARONSON| JOHN P|||PRIMARY |P
|000111|567894521|||||||ATHENS| WILLIAM k|||AAAA|L
Expected:
|000222|123456987|||||||AARONSON| JOHN |P|||PRIMARY |P
|000111|567894521|||||||ATHENS| WILLIAM |k|||AAAA|L
I... (6 Replies)
Hi All,
I have two files as below:
file1 file2
AAAA CCCC,1234,0909
BBBBB AAAA,1234
AAAA DDDD,23536,9090
CCCC
DDDD
EEEEE
I want a out file as below
AAAA,1234
BBBB
AAAA,1234... (5 Replies)
I am working with an undocumented feature of a software product (BladeLogic). It is returning the below string in response to a query. It is enclosed with square brackets, "records" are separated with commas and "fields" separated with semicolons. My thought was that this might be some basic... (1 Reply)
Hi all,
I have a file looks like
AAAA 111
BBBB 222
CCCC 333
need to pass variable value like var1=AAAA and var2=111
to another command for three times with next values.
stuck over here
cat file | while read line
do
export var1=`awk '{print $1}'`
echo $var1
export var2=`cat file... (3 Replies)