NLXOUT(3,L) AIX Technical Reference NLXOUT(3,L) ------------------------------------------------------------------------------- NLxout PURPOSE Performs ASCII-to-EBCDIC translation. LIBRARY Standard C Library (libc.a) SYNTAX int NLxout (s1, s2, n) char *s1, *s2; int n; DESCRIPTION The NLxout routine performs ASCII-to-EBCDIC translation based on the translation table named by the environment variable NLOUT. If NLOUT is not defined or is invalid, NLxout uses the default universal ASCII-to-EBCDIC translation table. s1 is a pointer to an output buffer used to store the translated EBCDIC data. s2 is a pointer to the null-terminated ASCII character data to be translated. n is the count of the number of bytes available in s1. NLxout uses the value of the environment variable NLOUT as a path name to the ASCII-to-EBCDIC translation table. (The inspection of the environment variable NLOUT is performed only at the first invocation of NLxout within a process. Subsequent invocations of NLxout from the same process will use the translation table obtained at the first invocation.) The byte values from the array s2 are used to index into the translation table to obtain the EBCDIC byte that is placed into the character array pointed to by s1. The translation proceeds on a byte-by-byte basis until a null-byte is encountered in the array pointed to by s2, or n bytes have been placed in the array pointed to by s1. RETURN VALUE NLxout returns the number of bytes placed in s1. RELATED INFORMATION The axeb, ebxa, and genxlt commands in AIX Operating System Commands Reference. Processed November 7, 1990 NLXOUT(3,L) 1
NLXOUT(3,L) AIX Technical Reference NLXOUT(3,L) The discussion on environment variables in AIX Operating System Programming Tools and Interfaces. Processed November 7, 1990 NLXOUT(3,L) 2