diff options
author | Damien Miller <djm@mindrot.org> | 2013-10-15 12:14:12 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2013-10-15 12:14:12 +1100 |
commit | e9fc72edd6c313b670558cd5219601c38a949b67 (patch) | |
tree | 32ed93978e93622d5829a55cbc0479e00b1161bf /misc.c | |
parent | 194fd904d8597a274b93e075b2047afdf5a175d4 (diff) | |
download | openssh-git-e9fc72edd6c313b670558cd5219601c38a949b67.tar.gz |
- djm@cvs.openbsd.org 2013/10/14 23:28:23
[canohost.c misc.c misc.h readconf.c sftp-server.c ssh.c]
refactor client config code a little:
add multistate option partsing to readconf.c, similar to servconf.c's
existing code.
move checking of options that accept "none" as an argument to readconf.c
add a lowercase() function and use it instead of explicit tolower() in
loops
part of a larger diff that was ok markus@
Diffstat (limited to 'misc.c')
-rw-r--r-- | misc.c | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -1,4 +1,4 @@ -/* $OpenBSD: misc.c,v 1.91 2013/07/12 00:43:50 djm Exp $ */ +/* $OpenBSD: misc.c,v 1.92 2013/10/14 23:28:23 djm Exp $ */ /* * Copyright (c) 2000 Markus Friedl. All rights reserved. * Copyright (c) 2005,2006 Damien Miller. All rights reserved. @@ -43,6 +43,7 @@ #include <netinet/ip.h> #include <netinet/tcp.h> +#include <ctype.h> #include <errno.h> #include <fcntl.h> #include <netdb.h> @@ -1017,6 +1018,13 @@ iptos2str(int iptos) snprintf(iptos_str, sizeof iptos_str, "0x%02x", iptos); return iptos_str; } + +void +lowercase(char *s) +{ + for (; *s; s++) + *s = tolower((u_char)*s); +} void sock_set_v6only(int s) { |