diff options
author | 2004-08-11 11:09:54 +0000 | |
---|---|---|
committer | 2004-08-11 11:09:54 +0000 | |
commit | e08d0d23cc3cf0b274274d30b9482ce0c2b332bb (patch) | |
tree | ffa996c5c6b3e91dccbe673be35dc032afe6cba2 | |
parent | mips64 now (diff) | |
download | wireguard-openbsd-e08d0d23cc3cf0b274274d30b9482ce0c2b332bb.tar.xz wireguard-openbsd-e08d0d23cc3cf0b274274d30b9482ce0c2b332bb.zip |
Fix minor leak; "looks right" deraadt@
-rw-r--r-- | usr.bin/ssh/servconf.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/ssh/servconf.c b/usr.bin/ssh/servconf.c index 23dcde0b111..54d9c217ba7 100644 --- a/usr.bin/ssh/servconf.c +++ b/usr.bin/ssh/servconf.c @@ -10,7 +10,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: servconf.c,v 1.135 2004/07/11 17:48:47 deraadt Exp $"); +RCSID("$OpenBSD: servconf.c,v 1.136 2004/08/11 11:09:54 dtucker Exp $"); #include "ssh.h" #include "log.h" @@ -933,18 +933,18 @@ void parse_server_config(ServerOptions *options, const char *filename, Buffer *conf) { int linenum, bad_options = 0; - char *cp, *cbuf; + char *cp, *obuf, *cbuf; debug2("%s: config %s len %d", __func__, filename, buffer_len(conf)); - cbuf = xstrdup(buffer_ptr(conf)); + obuf = cbuf = xstrdup(buffer_ptr(conf)); linenum = 0; while((cp = strsep(&cbuf, "\n")) != NULL) { if (process_server_config_line(options, cp, filename, linenum++) != 0) bad_options++; } - free(cbuf); + xfree(obuf); if (bad_options > 0) fatal("%s: terminating, %d bad configuration options", filename, bad_options); |