Logo Search packages:      
Sourcecode: ldns version File versions  Download package

ldns_rr_type ldns_rdf2rr_type ( const ldns_rdf rd  ) 

convert an rdf of type LDNS_RDF_TYPE_TYPE to an actual LDNS_RR_TYPE. This is usefull in the case when inspecting the rrtype covered field of an RRSIG.

Parameters:
[in] rd the rdf to look at
Returns:
a ldns_rr_type with equivalent LDNS_RR_TYPE

Definition at line 2096 of file rr.c.

References ldns_rdf2native_int16(), ldns_rdf2rr_type(), ldns_rdf_get_type(), and LDNS_RDF_TYPE_TYPE.

Referenced by ldns_rdf2rr_type().

{
        ldns_rr_type r;

        if (!rd) {
                return 0;
        }

        if (ldns_rdf_get_type(rd) != LDNS_RDF_TYPE_TYPE) {
                return 0;
        }

        r = (ldns_rr_type) ldns_rdf2native_int16(rd);
        return r;
}


Generated by  Doxygen 1.6.0   Back to index