diff options
author | Michael Kerrisk <mtk.manpages@gmail.com> | 2007-05-16 04:17:19 +0000 |
---|---|---|
committer | Michael Kerrisk <mtk.manpages@gmail.com> | 2007-05-16 04:17:19 +0000 |
commit | 5aa145bd2a876f37c737a1235b769ac3cae153fa (patch) | |
tree | 5c0e8245bfb379018bfbe194860982b848572499 /man3/encrypt.3 | |
parent | 6459c9ca10ab8d64ff221711c1c8a2239378a2da (diff) |
Removed statement that glibc unconditionally exposes declarations
of encrypt() and setkey(), since portable applications must
use <unistd.h> and define _XOPEN_SOURCE to obtain the declarations
of setkey() and encrypt(). Adjusted example program accordingly.
Diffstat (limited to 'man3/encrypt.3')
-rw-r--r-- | man3/encrypt.3 | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/man3/encrypt.3 b/man3/encrypt.3 index d30395521..d3552077a 100644 --- a/man3/encrypt.3 +++ b/man3/encrypt.3 @@ -116,14 +116,11 @@ The function is not provided. You need to link with libcrypt to compile this example with glibc 2.2. To do useful work the key[] and txt[] arrays must be filled with a useful bit pattern. -Note that the <crypt.h> header unconditionally -gives the prototypes for -.BR setkey () -and -.BR encrypt (). .sp .nf -#include <crypt.h> +#define _XOPEN_SOURCE +#include <unistd.h> +#include <stdlib.h> int main(void) |