1*99410184Ssalo.\" $NetBSD: catopen.3,v 1.14 2003/07/26 19:24:49 salo Exp $ 27ce7ea94Scgd.\" 3*99410184Ssalo.\" Written by J.T. Conklin <jtc@NetBSD.org>. 49ae90685Sjtc.\" Public domain. 51a5e3601Sjtc.\" 61a5e3601Sjtc.Dd May 29, 1994 71a5e3601Sjtc.Dt CATOPEN 3 81a5e3601Sjtc.Os 91a5e3601Sjtc.Sh NAME 101a5e3601Sjtc.Nm catopen 111a5e3601Sjtc.Nd open message catalog 12312aca53Sperry.Sh LIBRARY 13312aca53Sperry.Lb libc 141a5e3601Sjtc.Sh SYNOPSIS 15472351e1Swiz.In nl_types.h 161a5e3601Sjtc.Ft nl_catd 17517b8690Scgd.Fn catopen "const char *name" "int oflag" 181a5e3601Sjtc.Sh DESCRIPTION 19517b8690ScgdThe 20517b8690Scgd.Fn catopen 21517b8690Scgdfunction opens the message catalog specified by 221a5e3601Sjtc.Fa name 231a5e3601Sjtcand returns a message catalog descriptor. 241a5e3601SjtcIf 251a5e3601Sjtc.Fa name 261a5e3601Sjtccontains a 271a5e3601Sjtc.Sq / 281a5e3601Sjtcthen 291a5e3601Sjtc.Fa name 301a5e3601Sjtcspecifies the full pathname for the message catalog, otherwise the value 311a5e3601Sjtcof the environment variable 321a5e3601Sjtc.Ev NLSPATH 331a5e3601Sjtcis used with 341a5e3601Sjtc.Fa name 351a5e3601Sjtcsubstituted for %N. 361a5e3601Sjtc.Pp 371a5e3601SjtcThe 381a5e3601Sjtc.Fa oflag 391a5e3601Sjtcargument is reserved for future use and should be set to zero. 405f0cf559Swiz.Sh RETURN VALUES 411a5e3601SjtcUpon successful completion, 421a5e3601Sjtc.Fn catopen 431a5e3601Sjtcreturns a message catalog descriptor. 441a5e3601SjtcOtherwise, (nl_catd) -1 is returned and 451a5e3601Sjtc.Va errno 461a5e3601Sjtcis set to indicate the error. 471a5e3601Sjtc.Sh ERRORS 481a5e3601Sjtc.Bl -tag -width Er 491a5e3601Sjtc.It Bq Er ENOMEM 507828991aSwizInsufficient memory is available. 511a5e3601Sjtc.El 521a5e3601Sjtc.Sh SEE ALSO 530d72c029Sgmcgarry.Xr gencat 1 , 541a5e3601Sjtc.Xr catclose 3 , 551b19306fSgmcgarry.Xr catgets 3 , 561b19306fSgmcgarry.Xr nls 7 576dca6010Sjtc.Sh STANDARDS 586dca6010SjtcThe 596dca6010Sjtc.Fn catopen 606dca6010Sjtcfunction conforms to 616dca6010Sjtc.St -xpg3 . 62