Module Name:    src
Committed By:   jdolecek
Date:           Sun Oct 14 17:40:28 UTC 2018

Modified Files:
        src/share/man/man9: malloc.9

Log Message:
remove M_CANFAIL from list of supported flags for malloc(9)


To generate a diff of this commit:
cvs rdiff -u -r1.54 -r1.55 src/share/man/man9/malloc.9

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/share/man/man9/malloc.9
diff -u src/share/man/man9/malloc.9:1.54 src/share/man/man9/malloc.9:1.55
--- src/share/man/man9/malloc.9:1.54	Mon Jul  3 21:28:48 2017
+++ src/share/man/man9/malloc.9	Sun Oct 14 17:40:28 2018
@@ -1,4 +1,4 @@
-.\"	$NetBSD: malloc.9,v 1.54 2017/07/03 21:28:48 wiz Exp $
+.\"	$NetBSD: malloc.9,v 1.55 2018/10/14 17:40:28 jdolecek Exp $
 .\"
 .\" Copyright (c) 1996, 2003 The NetBSD Foundation, Inc.
 .\" All rights reserved.
@@ -27,7 +27,7 @@
 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 .\" POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd August 7, 2015
+.Dd October 14, 2018
 .Dt MALLOC 9
 .Os
 .Sh NAME
@@ -126,7 +126,7 @@ The
 argument further qualifies
 .Fn malloc
 operational characteristics as follows:
-.Bl -tag -offset indent -width M_CANFAIL
+.Bl -tag -offset indent -width M_NOWAIT
 .It Dv M_NOWAIT
 Causes
 .Fn malloc
@@ -153,22 +153,6 @@ is conveniently defined to be 0, and hen
 argument to indicate that it's ok to wait for resources.
 .It Dv M_ZERO
 Causes the allocated memory to be set to all zeros.
-.It Dv M_CANFAIL
-Changes behaviour for
-.Dv M_WAITOK
-case - if the requested memory size is bigger than
-.Fn malloc
-can ever allocate, return failure, rather than calling
-.Xr panic 9 .
-This is different to M_NOWAIT, since
-the call can still wait for resources.
-.Pp
-Rather than depending on
-.Dv M_CANFAIL ,
-kernel code should do proper bound checking itself.
-This flag should only be used in cases where this is not feasible.
-Since it can hide real kernel bugs, its usage is
-.Em strongly discouraged .
 .El
 .Pp
 The

Reply via email to