From ca130fe4651a2ca547b05187bdc2804defc8a66b Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Wed, 8 Aug 2001 21:25:01 +0000 Subject: Update. * catgets/open_catalog.c: Rewrite code to assume that the function is called at catopen time and not delayed in catgets. * catgets/catgets.c (catopen): Call __open_catalog and fail if that function failed. (catgets): Remove code for delayed opening of catalog. * catgets/catgetsinfo.h: Remove now unnecessary information from struct catalog_info. Change __open_catalog prototype. * catgets/gencat.c: Adjust __open_catalog call. * catgets/test-gencat.c: Stop program if catopen failed. --- catgets/catgetsinfo.h | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'catgets/catgetsinfo.h') diff --git a/catgets/catgetsinfo.h b/catgets/catgetsinfo.h index d40b419..d4aa003 100644 --- a/catgets/catgetsinfo.h +++ b/catgets/catgetsinfo.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1996, 1997 Free Software Foundation, Inc. +/* Copyright (C) 1996, 1997, 2001 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper, . @@ -18,7 +18,6 @@ 02111-1307 USA. */ #include -#include struct catalog_obj @@ -35,11 +34,7 @@ struct catalog_obj /* This structure will be filled after loading the catalog. */ typedef struct catalog_info { - enum { closed, nonexisting, mmapped, malloced } status; - - const char *cat_name; - const char *env_var; - const char *nlspath; + enum { mmapped, malloced } status; size_t plane_size; size_t plane_depth; @@ -48,8 +43,6 @@ typedef struct catalog_info struct catalog_obj *file_ptr; size_t file_size; - - __libc_lock_define (,lock); } *__nl_catd; @@ -59,4 +52,5 @@ typedef struct catalog_info /* Prototypes for helper functions. */ -void __open_catalog (__nl_catd __catalog); +extern int __open_catalog (const char *cat_name, const char *nlspath, + const char *env_var, __nl_catd __catalog); -- cgit v1.1