summaryrefslogtreecommitdiffstats
path: root/lib/libc/stdlib
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/stdlib')
-rw-r--r--lib/libc/stdlib/abs.32
-rw-r--r--lib/libc/stdlib/atexit.34
-rw-r--r--lib/libc/stdlib/atof.34
-rw-r--r--lib/libc/stdlib/atoi.34
-rw-r--r--lib/libc/stdlib/div.36
-rw-r--r--lib/libc/stdlib/getenv.327
-rw-r--r--lib/libc/stdlib/labs.32
-rw-r--r--lib/libc/stdlib/ldiv.310
-rw-r--r--lib/libc/stdlib/malloc.32
-rw-r--r--lib/libc/stdlib/strtod.32
10 files changed, 32 insertions, 31 deletions
diff --git a/lib/libc/stdlib/abs.3 b/lib/libc/stdlib/abs.3
index 9dee8ed..d9296ef 100644
--- a/lib/libc/stdlib/abs.3
+++ b/lib/libc/stdlib/abs.3
@@ -54,7 +54,7 @@ The
function
computes
the absolute value of the integer
-.Ar j .
+.Fa j .
.Sh RETURN VALUES
The
.Fn abs
diff --git a/lib/libc/stdlib/atexit.3 b/lib/libc/stdlib/atexit.3
index 9aae7af..b3dec68 100644
--- a/lib/libc/stdlib/atexit.3
+++ b/lib/libc/stdlib/atexit.3
@@ -53,11 +53,11 @@ The
.Fn atexit
function
registers the given
-.Ar function
+.Fa function
to be called at program exit, whether via
.Xr exit 3
or via return from the program's
-.Em main .
+.Fn main .
Functions so registered are called in reverse order;
no arguments are passed.
.Pp
diff --git a/lib/libc/stdlib/atof.3 b/lib/libc/stdlib/atof.3
index 10fcf49..d338e3d 100644
--- a/lib/libc/stdlib/atof.3
+++ b/lib/libc/stdlib/atof.3
@@ -54,9 +54,9 @@ string to double
The
.Fn atof
function converts the initial portion of the string pointed to by
-.Ar nptr
+.Fa nptr
to
-.Ar double
+.Vt double
representation.
.Pp
It is equivalent to:
diff --git a/lib/libc/stdlib/atoi.3 b/lib/libc/stdlib/atoi.3
index 19269a5..34a1b2d 100644
--- a/lib/libc/stdlib/atoi.3
+++ b/lib/libc/stdlib/atoi.3
@@ -54,9 +54,9 @@ string to integer
The
.Fn atoi
function converts the initial portion of the string pointed to by
-.Em nptr
+.Fa nptr
to
-.Em integer
+.Vt int
representation.
.Pp
It is equivalent to:
diff --git a/lib/libc/stdlib/div.3 b/lib/libc/stdlib/div.3
index 31fc742..05567fb 100644
--- a/lib/libc/stdlib/div.3
+++ b/lib/libc/stdlib/div.3
@@ -55,11 +55,11 @@ computes the value
and returns the quotient and remainder in a structure named
.Fa div_t
that contains two
-.Em int
+.Vt int
members named
-.Fa quot
+.Va quot
and
-.Fa rem .
+.Va rem .
.Sh SEE ALSO
.Xr imaxdiv 3 ,
.Xr ldiv 3 ,
diff --git a/lib/libc/stdlib/getenv.3 b/lib/libc/stdlib/getenv.3
index 2b46e52..269fecb 100644
--- a/lib/libc/stdlib/getenv.3
+++ b/lib/libc/stdlib/getenv.3
@@ -63,9 +63,9 @@ host
.Em environment list .
For compatibility with differing environment conventions,
the given arguments
-.Ar name
+.Fa name
and
-.Ar value
+.Fa value
may be appended and prepended,
respectively,
with an equal sign
@@ -74,30 +74,31 @@ with an equal sign
The
.Fn getenv
function obtains the current value of the environment variable,
-.Ar name .
+.Fa name .
If the variable
-.Ar name
+.Fa name
is not in the current environment,
a null pointer is returned.
.Pp
The
.Fn setenv
function inserts or resets the environment variable
-.Ar name
+.Fa name
in the current environment list.
If the variable
-.Ar name
+.Fa name
does not exist in the list,
it is inserted with the given
-.Ar value .
+.Fa value .
If the variable does exist, the argument
-.Ar overwrite
+.Fa overwrite
is tested; if
-.Ar overwrite is
+.Fa overwrite
+is
zero, the
variable is not reset, otherwise it is reset
to the given
-.Ar value .
+.Fa value .
.Pp
The
.Fn putenv
@@ -140,14 +141,14 @@ Successive calls to
or
.Fn putenv
assigning a differently sized
-.Ar value
+.Fa value
to the same
-.Ar name
+.Fa name
will result in a memory leak. The
.Fx
semantics for these functions
(namely, that the contents of
-.Ar value
+.Fa value
are copied and that old values remain accessible indefinitely) make this
bug unavoidable. Future versions may eliminate one or both of these
semantic guarantees in order to fix the bug.
diff --git a/lib/libc/stdlib/labs.3 b/lib/libc/stdlib/labs.3
index 9831bdb..2c8db6e 100644
--- a/lib/libc/stdlib/labs.3
+++ b/lib/libc/stdlib/labs.3
@@ -53,7 +53,7 @@ The
.Fn labs
function
returns the absolute value of the long integer
-.Ar j .
+.Fa j .
.Sh SEE ALSO
.Xr abs 3 ,
.Xr cabs 3 ,
diff --git a/lib/libc/stdlib/ldiv.3 b/lib/libc/stdlib/ldiv.3
index 8e09cdf..eddf9db 100644
--- a/lib/libc/stdlib/ldiv.3
+++ b/lib/libc/stdlib/ldiv.3
@@ -53,15 +53,15 @@ The
.Fn ldiv
function
computes the value
-.Ar num/denom
+.Fa num Ns / Ns Fa denom
and returns the quotient and remainder in a structure named
-.Ar ldiv_t
+.Vt ldiv_t
that contains two
-.Em long integer
+.Vt long
members named
-.Ar quot
+.Va quot
and
-.Ar rem .
+.Va rem .
.Sh SEE ALSO
.Xr div 3 ,
.Xr imaxdiv 3 ,
diff --git a/lib/libc/stdlib/malloc.3 b/lib/libc/stdlib/malloc.3
index 6c11ea7..8fa0326 100644
--- a/lib/libc/stdlib/malloc.3
+++ b/lib/libc/stdlib/malloc.3
@@ -69,7 +69,7 @@ bytes of memory.
The allocated space is suitably aligned (after possible pointer coercion)
for storage of any type of object.
If the space is at least
-.Em pagesize
+.Va pagesize
bytes in length (see
.Xr getpagesize 3 ) ,
the returned memory will be page boundary aligned as well.
diff --git a/lib/libc/stdlib/strtod.3 b/lib/libc/stdlib/strtod.3
index e261455..ab78083 100644
--- a/lib/libc/stdlib/strtod.3
+++ b/lib/libc/stdlib/strtod.3
@@ -57,7 +57,7 @@ function converts the initial portion of the string
pointed to by
.Fa nptr
to
-.Em double
+.Vt double
representation.
.Pp
The expected form of the string is an optional plus (``+'') or minus
OpenPOWER on IntegriCloud