Module Name:    src
Committed By:   joerg
Date:           Sat Jan 18 02:31:14 UTC 2014

Modified Files:
        src/tests/crypto/opencrypto: h_md5hmac.c h_sha1hmac.c

Log Message:
Needs some unconst.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/crypto/opencrypto/h_md5hmac.c
cvs rdiff -u -r1.1 -r1.2 src/tests/crypto/opencrypto/h_sha1hmac.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/tests/crypto/opencrypto/h_md5hmac.c
diff -u src/tests/crypto/opencrypto/h_md5hmac.c:1.3 src/tests/crypto/opencrypto/h_md5hmac.c:1.4
--- src/tests/crypto/opencrypto/h_md5hmac.c:1.3	Fri Jan 17 22:31:25 2014
+++ src/tests/crypto/opencrypto/h_md5hmac.c	Sat Jan 18 02:31:14 2014
@@ -1,4 +1,4 @@
-/* $NetBSD: h_md5hmac.c,v 1.3 2014/01/17 22:31:25 pgoyette Exp $ */
+/* $NetBSD: h_md5hmac.c,v 1.4 2014/01/18 02:31:14 joerg Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -154,7 +154,7 @@ main(void)
 		memset(&cs, 0, sizeof(cs));
 		cs.mac = CRYPTO_MD5_HMAC;
 		cs.mackeylen = tests[i].key_len;
-		cs.mackey = &tests[i].key;
+		cs.mackey = __UNCONST(&tests[i].key);
 		res = ioctl(fd, CIOCGSESSION, &cs);
 		if (res < 0)
 			err(1, "CIOCGSESSION test %d", tests[i].num);
@@ -164,7 +164,7 @@ main(void)
 		co.ses = cs.ses;
 		co.op = COP_ENCRYPT;
 		co.len = tests[i].len;
-		co.src = &tests[i].data;
+		co.src = __UNCONST(&tests[i].data);
 		co.mac = buf;
 		res = ioctl(fd, CIOCCRYPT, &co);
 		if (res < 0)

Index: src/tests/crypto/opencrypto/h_sha1hmac.c
diff -u src/tests/crypto/opencrypto/h_sha1hmac.c:1.1 src/tests/crypto/opencrypto/h_sha1hmac.c:1.2
--- src/tests/crypto/opencrypto/h_sha1hmac.c:1.1	Fri Jan 17 22:33:02 2014
+++ src/tests/crypto/opencrypto/h_sha1hmac.c	Sat Jan 18 02:31:14 2014
@@ -1,4 +1,4 @@
-/* $NetBSD: h_sha1hmac.c,v 1.1 2014/01/17 22:33:02 pgoyette Exp $ */
+/* $NetBSD: h_sha1hmac.c,v 1.2 2014/01/18 02:31:14 joerg Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -164,7 +164,7 @@ main(void)
 		memset(&cs, 0, sizeof(cs));
 		cs.mac = CRYPTO_SHA1_HMAC;
 		cs.mackeylen = tests[i].key_len;
-		cs.mackey = &tests[i].key;;
+		cs.mackey = __UNCONST(&tests[i].key);
 		res = ioctl(fd, CIOCGSESSION, &cs);
 		if (res < 0)
 			err(1, "CIOCGSESSION test %d", tests[i].num);
@@ -174,7 +174,7 @@ main(void)
 		co.ses = cs.ses;
 		co.op = COP_ENCRYPT;
 		co.len = tests[i].len;
-		co.src = &tests[i].data;
+		co.src = __UNCONST(&tests[i].data);
 		co.mac = buf;
 		res = ioctl(fd, CIOCCRYPT, &co);
 		if (res < 0)

Reply via email to