diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2014-10-31 15:54:15 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2014-10-31 15:54:15 +0000 |
commit | 83c55da9b2cc7fb34e246561a2b797a15d8657b4 (patch) | |
tree | db834dc917396c9907c54cda5d3b3ea1ec6effc9 | |
parent | ec8faacc90bf21220b63c8e488d0caa52b8d4a57 (diff) |
Use "const char tempchars[]" instead of "const char *tempchars".
Since tempchars is never reassigned there's no need to indirect
through a pointer. Still getting used to this newfangled C89.
-rw-r--r-- | lib/libc/stdio/mktemp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/stdio/mktemp.c b/lib/libc/stdio/mktemp.c index 2a17e522f03..956608c151d 100644 --- a/lib/libc/stdio/mktemp.c +++ b/lib/libc/stdio/mktemp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mktemp.c,v 1.34 2014/08/31 02:21:18 guenther Exp $ */ +/* $OpenBSD: mktemp.c,v 1.35 2014/10/31 15:54:14 millert Exp $ */ /* * Copyright (c) 1996-1998, 2008 Theo de Raadt * Copyright (c) 1997, 2008-2009 Todd C. Miller @@ -45,7 +45,7 @@ static int mktemp_internal(char *path, int slen, int mode, int flags) { char *start, *cp, *ep; - const char *tempchars = TEMPCHARS; + const char tempchars[] = TEMPCHARS; unsigned int tries; struct stat sb; size_t len; |