summaryrefslogtreecommitdiffstats
path: root/man3/cfree.3
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-24 04:52:22 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-24 04:52:22 +0000
commit3d08cd331c1adcf0d917392f7e527b3f00511748 (patch)
tree312f0d1e1632f48862f044b8bb87e602dcffb5f9 /man3/cfree.3
parentAdding debian version 6.7-2. (diff)
downloadmanpages-3d08cd331c1adcf0d917392f7e527b3f00511748.tar.xz
manpages-3d08cd331c1adcf0d917392f7e527b3f00511748.zip
Merging upstream version 6.8.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'man3/cfree.3')
-rw-r--r--man3/cfree.3132
1 files changed, 0 insertions, 132 deletions
diff --git a/man3/cfree.3 b/man3/cfree.3
deleted file mode 100644
index 97d30b6..0000000
--- a/man3/cfree.3
+++ /dev/null
@@ -1,132 +0,0 @@
-'\" t
-.\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
-.\"
-.\" SPDX-License-Identifier: GPL-2.0-or-later
-.\"
-.TH cfree 3 2023-10-31 "Linux man-pages 6.7"
-.SH NAME
-cfree \- free allocated memory
-.SH LIBRARY
-Standard C library
-.RI ( libc ", " \-lc )
-.SH SYNOPSIS
-.nf
-.P
-.B "#include <stdlib.h>"
-.P
-/* In SunOS 4 */
-.BI "int cfree(void *" ptr );
-.P
-/* In glibc or FreeBSD libcompat */
-.BI "void cfree(void *" ptr );
-.P
-/* In SCO OpenServer */
-.BI "void cfree(char " ptr [. size " * ." num "], unsigned int " num ", \
-unsigned int " size );
-.P
-/* In Solaris watchmalloc.so.1 */
-.BI "void cfree(void " ptr [. elsize " * ." nelem "], size_t " nelem ", \
-size_t " elsize );
-.fi
-.P
-.RS -4
-Feature Test Macro Requirements for glibc (see
-.BR feature_test_macros (7)):
-.RE
-.P
-.BR cfree ():
-.nf
- Since glibc 2.19:
- _DEFAULT_SOURCE
- glibc 2.19 and earlier:
- _BSD_SOURCE || _SVID_SOURCE
-.fi
-.SH DESCRIPTION
-This function should never be used.
-Use
-.BR free (3)
-instead.
-Starting with glibc 2.26, it has been removed from glibc.
-.SS 1-arg cfree
-In glibc, the function
-.BR cfree ()
-is a synonym for
-.BR free (3),
-"added for compatibility with SunOS".
-.P
-Other systems have other functions with this name.
-The declaration is sometimes in
-.I <stdlib.h>
-and sometimes in
-.IR <malloc.h> .
-.SS 3-arg cfree
-Some SCO and Solaris versions have malloc libraries with a 3-argument
-.BR cfree (),
-apparently as an analog to
-.BR calloc (3).
-.P
-If you need it while porting something, add
-.P
-.in +4n
-.EX
-#define cfree(p, n, s) free((p))
-.EE
-.in
-.P
-to your file.
-.P
-A frequently asked question is "Can I use
-.BR free (3)
-to free memory allocated with
-.BR calloc (3),
-or do I need
-.BR cfree ()?"
-Answer: use
-.BR free (3).
-.P
-An SCO manual writes: "The cfree routine is provided for compliance
-to the iBCSe2 standard and simply calls free.
-The num and size
-arguments to cfree are not used."
-.SH RETURN VALUE
-The SunOS version of
-.BR cfree ()
-(which is a synonym for
-.BR free (3))
-returns 1 on success and 0 on failure.
-In case of error,
-.I errno
-is set to
-.BR EINVAL :
-the value of
-.I ptr
-was not a pointer to a block previously allocated by
-one of the routines in the
-.BR malloc (3)
-family.
-.SH ATTRIBUTES
-For an explanation of the terms used in this section, see
-.BR attributes (7).
-.TS
-allbox;
-lbx lb lb
-l l l.
-Interface Attribute Value
-T{
-.na
-.nh
-.BR cfree ()
-T} Thread safety MT-Safe /* In glibc */
-.TE
-.SH VERSIONS
-The 3-argument version of
-.BR cfree ()
-as used by SCO conforms to the iBCSe2 standard:
-Intel386 Binary Compatibility Specification, Edition 2.
-.SH STANDARDS
-None.
-.SH HISTORY
-.\" commit 025b33ae84bb8f15b2748a1d8605dca453fce112
-Removed in glibc 2.26.
-.SH SEE ALSO
-.BR malloc (3)