]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
tweak conditionals to work with knot 3.0.dev obs-knot-dns-deve-jq0xxt/deployments/309
authorVladimír Čunát <vladimir.cunat@nic.cz>
Mon, 21 Oct 2019 12:32:51 +0000 (14:32 +0200)
committerVladimír Čunát <vladimir.cunat@nic.cz>
Mon, 21 Oct 2019 12:34:14 +0000 (14:34 +0200)
I didn't plan this well ahead :-/

lib/cache/entry_rr.c
lib/zonecut.h
modules/edns_keepalive/edns_keepalive.c
modules/nsid/nsid.c

index f6d9168ad2b7a6c67255f95420ff396514722770..ecb358abd95169959600c2d7aaeb98cc8a9740e0 100644 (file)
@@ -59,7 +59,7 @@ static int rdataset_materialize(knot_rdataset_t * restrict rds, const uint8_t *
        /* TODO: we might overrun here already, but we need to trust cache anyway...*/
        const uint32_t rds_size = rdataset_dematerialized_size(d, &rds->count);
        d += KR_CACHE_RR_COUNT_SIZE;
-       #if KNOT_VERSION_MINOR >= 9
+       #if KNOT_VERSION_HEX >= 0x020900
                rds->size = rds_size;
        #endif
        if (d + rds_size > data_bound) {
index 4de4087c0fc1fe5fa425517798967b8b371557af..e2eb553e1a67dfcae4584af4619be668c96f4ae6 100644 (file)
@@ -23,7 +23,7 @@
 
 
 /* TMP: compatibility for using libknot 2.8 API with 2.9. */
-#if KNOT_VERSION_MINOR >= 9
+#if KNOT_VERSION_HEX >= 0x020900
 static inline size_t knot_rdataset_size(const knot_rdataset_t *rrs)
 {
        return rrs->size;
index 75767ca7e8a2b3a5addad1a795f3e5f3c13e374d..3a62b911990aba5d83e6f15801f88a1a0be277a9 100644 (file)
@@ -37,7 +37,7 @@ static int edns_keepalive_finalize(kr_layer_t *ctx)
                req->qsource.flags.tcp &&
                src_opt != NULL &&
                knot_edns_get_option(src_opt, KNOT_EDNS_OPTION_TCP_KEEPALIVE
-                                       #if KNOT_VERSION_MINOR >= 9
+                                       #if KNOT_VERSION_HEX >= 0x020900
                                                , NULL
                                        #endif
                                ) &&
index fee2da1e13fc996c85c8588220a24d69ce70234a..67263a46316baef7b955ed2a97c5fca4f830afd6 100644 (file)
@@ -31,7 +31,7 @@ static int nsid_finalize(kr_layer_t *ctx) {
                return ctx->state;
 
        const uint8_t *req_nsid = knot_edns_get_option(src_opt, KNOT_EDNS_OPTION_NSID
-                                                       #if KNOT_VERSION_MINOR >= 9
+                                                       #if KNOT_VERSION_HEX >= 0x020900
                                                                , NULL
                                                        #endif
                                                        );