summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorajs <ajs>2005-04-08 18:50:40 +0000
committerajs <ajs>2005-04-08 18:50:40 +0000
commit926fe8f1fce88d0889e47a9f5c6d78c6bc11f3f6 (patch)
tree78e9dc040253454b518a1a7bab6468a2cbceeb89
parentd66a7b56634f88181dd2dd23706c30bf23366424 (diff)
2005-04-08 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
* vty.c: (vty_log_fixed) Use casts to (void *) to try to eliminate compiler warnings when assigning a (const char *) value to struct iovec iov_base.
-rw-r--r--lib/ChangeLog6
-rw-r--r--lib/vty.c4
2 files changed, 8 insertions, 2 deletions
diff --git a/lib/ChangeLog b/lib/ChangeLog
index 86a3b856..a6f3ca49 100644
--- a/lib/ChangeLog
+++ b/lib/ChangeLog
@@ -1,5 +1,11 @@
2005-04-08 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
+ * vty.c: (vty_log_fixed) Use casts to (void *) to try to eliminate
+ compiler warnings when assigning a (const char *) value to
+ struct iovec iov_base.
+
+2005-04-08 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
+
* zebra.h: If GNU_LINUX is defined, then define _GNU_SOURCE. This
fixes a problem where we were not getting the declaration of strnlen
in <string.h>.
diff --git a/lib/vty.c b/lib/vty.c
index 44439a94..600c9fd8 100644
--- a/lib/vty.c
+++ b/lib/vty.c
@@ -2395,9 +2395,9 @@ vty_log_fixed (const char *buf, size_t len)
unsigned int i;
struct iovec iov[2];
- iov[0].iov_base = buf;
+ iov[0].iov_base = (void *)buf;
iov[0].iov_len = len;
- iov[1].iov_base = "\r\n";
+ iov[1].iov_base = (void *)"\r\n";
iov[1].iov_len = 2;
for (i = 0; i < vector_active (vtyvec); i++)