From 50ecce4ef0dbc37f18a399040ed40e18539246ac Mon Sep 17 00:00:00 2001 From: Ted Unangst Date: Mon, 20 Jun 2011 18:04:07 +0000 Subject: as man page states, lower case undoes upper case. add support for little s, no security, for consistency. use of this option is discouraged. :) ok deraadt guenther millert --- lib/libc/stdlib/malloc.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/libc/stdlib/malloc.c b/lib/libc/stdlib/malloc.c index bdc6ca69d3d..976880e757b 100644 --- a/lib/libc/stdlib/malloc.c +++ b/lib/libc/stdlib/malloc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: malloc.c,v 1.137 2011/05/20 20:02:08 otto Exp $ */ +/* $OpenBSD: malloc.c,v 1.138 2011/06/20 18:04:06 tedu Exp $ */ /* * Copyright (c) 2008 Otto Moerbeek * @@ -548,6 +548,10 @@ omalloc_init(struct dir_info **dp) case 'R': mopts.malloc_realloc = 1; break; + case 's': + mopts.malloc_freeprot = mopts.malloc_junk = 0; + mopts.malloc_guard = 0; + break; case 'S': mopts.malloc_freeprot = mopts.malloc_junk = 1; mopts.malloc_guard = MALLOC_PAGESIZE; -- cgit v1.2.3