Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ catgetmsg(2) — AIX PS/2 1.2.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

gencat

mkcatdefs

AIX Operating System Commands

message catalog description in Managing the AIX Operating



CATGETMSG(2,L)              AIX Technical Reference              CATGETMSG(2,L)



-------------------------------------------------------------------------------
catgetmsg



PURPOSE

Retrieve a message from an open message catalog into a buffer.

LIBRARY

Standard C Library (libc.a)

SYNTAX

#include <nl_types.h>

char *catgetmsg (catd, set_num, msg_num, buf, buflen)
nl_catd catd;
int set_num, msg_num;
char *buf;
int buflen;

DESCRIPTION

The catgetmsg subroutine reads a message from an open message catalog into a
buffer.  The catd catalog descriptor is returned from a successful catopen,
set_num and msg_num specify the set and message from the catalog to retrieve,
and buf is a user defined buffer to store the message and buflen in bytes.  The
catgetmsg subroutine attempts to read up to buflen-1 bytes of a message string
into buf.  The message is specified by the set_num and msg_num parameters.  The
message in buf is terminated with a NULL byte.  catgetmsg does not split a
multibyte character.  This may lead to the message being truncated with up to
buflen-4 bytes placed in buf before the NULL byte.

RETURN VALUE

A pointer to buf is returned upon success of catgetmsg.  A NULL pointer is
returned upon any failure.

RELATED INFORMATION

The gencat and mkcatdefs commands in the AIX Operating System Commands
Reference.  The message catalog description in Managing the AIX Operating
System.










Processed November 7, 1990      CATGETMSG(2,L)                                1



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026