summaryrefslogtreecommitdiffstats
path: root/lib/libutil/opendev.c
diff options
context:
space:
mode:
authormillert <millert@openbsd.org>2010-12-17 19:35:34 +0000
committermillert <millert@openbsd.org>2010-12-17 19:35:34 +0000
commit27ad9b61aaee478f382f1b7e78ae1792cfa0e5bd (patch)
tree3297bafaeae4bf1196f977c712cb8f86818e0dbd /lib/libutil/opendev.c
parent- attach to moxa uport110, from rivo nurges (diff)
downloadwireguard-openbsd-27ad9b61aaee478f382f1b7e78ae1792cfa0e5bd.tar.xz
wireguard-openbsd-27ad9b61aaee478f382f1b7e78ae1792cfa0e5bd.zip
opendev() path argument should be const. OK deraadt@
Diffstat (limited to 'lib/libutil/opendev.c')
-rw-r--r--lib/libutil/opendev.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libutil/opendev.c b/lib/libutil/opendev.c
index 5856cbd2bb7..b43cb819b79 100644
--- a/lib/libutil/opendev.c
+++ b/lib/libutil/opendev.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: opendev.c,v 1.11 2010/11/15 15:07:40 jsing Exp $ */
+/* $OpenBSD: opendev.c,v 1.12 2010/12/17 19:35:34 millert Exp $ */
/*
* Copyright (c) 2000, Todd C. Miller. All rights reserved.
@@ -46,7 +46,7 @@
* disklabel(8).
*/
int
-opendev(char *path, int oflags, int dflags, char **realpath)
+opendev(const char *path, int oflags, int dflags, char **realpath)
{
static char namebuf[PATH_MAX];
struct dk_diskmap dm;
@@ -55,7 +55,7 @@ opendev(char *path, int oflags, int dflags, char **realpath)
/* Initial state */
if (realpath)
- *realpath = path;
+ *realpath = (char *)path;
fd = -1;
errno = ENOENT;