mirror of
https://sourceware.org/git/glibc.git
synced 2025-08-01 10:06:57 +03:00
[BZ #322]
Update. * intl/dcigettext.c (DCIGETTEXT): Protect tfind/tsearch calls. * intl/dcigettext.c (_nl_find_msg): Call _nl_load_domain also if decided < 0. * intl/finddomain.c (_nl_find_domain): Likewise. * intl/l10nflist.c (_nl_make_l10nflist): Initialize lock. * intl/loadinfo.h (struct loaded_l10nfile): Add lock element. * intl/loadmsgcat.c (_nl_load_domain): Set decided to 1 only once we are done. First set to -1 to signal initialization is ongoing. Protect against concurrent callers with recursive lock. duplicate address recognition does not copy junk. [BZ #322]
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 1996-2000, 2002, 2003 Free Software Foundation, Inc.
|
||||
/* Copyright (C) 1996-2000, 2002, 2003, 2004 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
|
||||
|
||||
@ -20,6 +20,8 @@
|
||||
#ifndef _LOADINFO_H
|
||||
#define _LOADINFO_H 1
|
||||
|
||||
#include <bits/libc-lock.h>
|
||||
|
||||
/* Declarations of locale dependent catalog lookup functions.
|
||||
Implemented in
|
||||
|
||||
@ -61,6 +63,7 @@ struct loaded_l10nfile
|
||||
{
|
||||
const char *filename;
|
||||
int decided;
|
||||
__libc_lock_define_recursive (, lock);
|
||||
|
||||
const void *data;
|
||||
|
||||
|
Reference in New Issue
Block a user