summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Josefsson <simon@josefsson.org>2009-05-13 15:06:14 +0200
committerSimon Josefsson <simon@josefsson.org>2009-05-13 15:06:14 +0200
commitbfba30be9bbde48211452a1362e4ad73a3fd57ab (patch)
tree0f8d32d5127063bf243b623a265da8a3631f71d1
parentb10b47cfd64b995c06f9e4f97d59786aca3382b0 (diff)
downloadgnutls-bfba30be9bbde48211452a1362e4ad73a3fd57ab.tar.gz
Fix warnings.
-rw-r--r--doc/examples/ex-client-tlsia.c3
-rw-r--r--lib/opencdk/literal.c4
-rw-r--r--lib/opencdk/misc.c4
-rw-r--r--src/common.c3
-rw-r--r--tests/chainverify.c2
-rw-r--r--tests/tlsia.c6
6 files changed, 12 insertions, 10 deletions
diff --git a/doc/examples/ex-client-tlsia.c b/doc/examples/ex-client-tlsia.c
index 86e30dcb74..9e78c9ad8d 100644
--- a/doc/examples/ex-client-tlsia.c
+++ b/doc/examples/ex-client-tlsia.c
@@ -34,7 +34,8 @@ client_avp (gnutls_session_t session, void *ptr,
{
if (last)
- printf ("- received %d bytes AVP: `%.*s'\n", lastlen, lastlen, last);
+ printf ("- received %d bytes AVP: `%.*s'\n",
+ lastlen, (int) lastlen, last);
else
printf ("- new application phase\n");
diff --git a/lib/opencdk/literal.c b/lib/opencdk/literal.c
index fc4ee4fdc3..d01b69a6e4 100644
--- a/lib/opencdk/literal.c
+++ b/lib/opencdk/literal.c
@@ -1,5 +1,5 @@
/* literal.c - Literal packet filters
- * Copyright (C) 2002, 2003, 2008 Free Software Foundation, Inc.
+ * Copyright (C) 2002, 2003, 2008, 2009 Free Software Foundation, Inc.
*
* Author: Timo Schulz
*
@@ -200,7 +200,7 @@ literal_encode (void *data, FILE * in, FILE * out)
filelen = strlen (pfx->filename);
cdk_pkt_new (&pkt);
pt = pkt->pkt.literal = cdk_calloc (1, sizeof *pt + filelen);
- pt->name = pt + sizeof(*pt);
+ pt->name = (char*) pt + sizeof(*pt);
if (!pt)
{
cdk_pkt_release (pkt);
diff --git a/lib/opencdk/misc.c b/lib/opencdk/misc.c
index 13e7fd5275..50977bfd49 100644
--- a/lib/opencdk/misc.c
+++ b/lib/opencdk/misc.c
@@ -1,5 +1,5 @@
/* misc.c
- * Copyright (C) 1998-2002, 2003, 2007, 2008 Free Software Foundation, Inc.
+ * Copyright (C) 1998-2002, 2003, 2007, 2008, 2009 Free Software Foundation, Inc.
*
* Author: Timo Schulz
*
@@ -97,7 +97,7 @@ cdk_strlist_add (cdk_strlist_t * list, const char *string)
sl = cdk_calloc (1, sizeof *sl + strlen (string) + 2);
if (!sl)
return NULL;
- sl->d = sl + sizeof(*sl);
+ sl->d = (char*) sl + sizeof(*sl);
strcpy (sl->d, string);
sl->next = *list;
*list = sl;
diff --git a/src/common.c b/src/common.c
index 226fdb750b..1e726e6e6f 100644
--- a/src/common.c
+++ b/src/common.c
@@ -356,7 +356,8 @@ print_dh_info (gnutls_session_t session, const char *str)
goto out;
}
- printf (" - PKCS#3 format:\n\n%.*s\n", params_data_size, params_data);
+ printf (" - PKCS#3 format:\n\n%.*s\n", (int) params_data_size,
+ params_data);
out:
gnutls_free (params_data);
diff --git a/tests/chainverify.c b/tests/chainverify.c
index 1595b5e84b..0bdee522c5 100644
--- a/tests/chainverify.c
+++ b/tests/chainverify.c
@@ -714,7 +714,7 @@ static struct
GNUTLS_CERT_SIGNER_NOT_FOUND | GNUTLS_CERT_INVALID },
{ "cacertrsamd5 short-cut ok", cacertrsamd5, &cacertrsamd5[1],
0, 0 },
- { NULL, NULL, NULL, 0}
+ { NULL, NULL, NULL, 0, 0}
};
/* *INDENT-ON* */
diff --git a/tests/tlsia.c b/tests/tlsia.c
index aac5d34b56..150eb30453 100644
--- a/tests/tlsia.c
+++ b/tests/tlsia.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation
+ * Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation
*
* Author: Simon Josefsson
*
@@ -59,7 +59,7 @@ client_avp (gnutls_session_t session, void *ptr,
if (last)
printf ("client: received %d bytes AVP: `%.*s'\n",
- lastlen, lastlen, last);
+ lastlen, (int) lastlen, last);
else
printf ("client: new application phase\n");
@@ -291,7 +291,7 @@ server_avp (gnutls_session_t session, void *ptr,
if (last)
printf ("server: received %d bytes AVP: `%.*s'\n",
- lastlen, lastlen, last);
+ lastlen, (int) lastlen, last);
gnutls_ia_permute_inner_secret (session, 3, "foo");