summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRikard Falkeborn <rikard.falkeborn@gmail.com>2020-04-27 12:07:34 +0200
committerDaniel Stenberg <daniel@haxx.se>2020-04-28 07:56:34 +0200
commitfc0e29dd57bb0dc7bbf4d0e5c9638b01f7b6afc6 (patch)
tree8f24df11dadfaace6b9fbc3ad9868c8acdd155ca /tests
parentcad15b9f92812ea4cdec6b65b7e2a83bdc007eb3 (diff)
downloadcurl-fc0e29dd57bb0dc7bbf4d0e5c9638b01f7b6afc6.tar.gz
doh: Constify some input pointers
Closes #5306
Diffstat (limited to 'tests')
-rw-r--r--tests/unit/unit1650.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/unit/unit1650.c b/tests/unit/unit1650.c
index 35ac12c81..502bf9df0 100644
--- a/tests/unit/unit1650.c
+++ b/tests/unit/unit1650.c
@@ -185,7 +185,7 @@ UNITTEST_START
size_t len;
int u;
memset(&d, 0, sizeof(d));
- rc = doh_decode((unsigned char *)resp[i].packet, resp[i].size,
+ rc = doh_decode((const unsigned char *)resp[i].packet, resp[i].size,
resp[i].type, &d);
if(rc != resp[i].rc) {
fprintf(stderr, "resp %zu: Expected return code %d got %d\n", i,
@@ -241,7 +241,7 @@ UNITTEST_START
struct dohentry d;
int rc;
memset(&d, 0, sizeof(d));
- rc = doh_decode((unsigned char *)full49, i, DNS_TYPE_A, &d);
+ rc = doh_decode((const unsigned char *)full49, i, DNS_TYPE_A, &d);
if(!rc) {
/* none of them should work */
fprintf(stderr, "%zu: %d\n", i, rc);
@@ -253,7 +253,7 @@ UNITTEST_START
struct dohentry d;
int rc;
memset(&d, 0, sizeof(d));
- rc = doh_decode((unsigned char *)&full49[i], sizeof(full49)-i-1,
+ rc = doh_decode((const unsigned char *)&full49[i], sizeof(full49)-i-1,
DNS_TYPE_A, &d);
if(!rc) {
/* none of them should work */
@@ -266,7 +266,7 @@ UNITTEST_START
struct dohentry d;
struct dohaddr *a;
memset(&d, 0, sizeof(d));
- rc = doh_decode((unsigned char *)full49, sizeof(full49)-1,
+ rc = doh_decode((const unsigned char *)full49, sizeof(full49)-1,
DNS_TYPE_A, &d);
fail_if(d.numaddr != 1, "missing address");
a = &d.addr[0];