1 |
/* This file is part of GNU RADIUS. |
/* This file is part of GNU Radius. |
2 |
Copyright (C) 2000, Sergey Poznyakoff |
Copyright (C) 2000,2001,2002,2003 Sergey Poznyakoff |
3 |
|
|
4 |
This program is free software; you can redistribute it and/or modify |
GNU Radius is free software; you can redistribute it and/or modify |
5 |
it under the terms of the GNU General Public License as published by |
it under the terms of the GNU General Public License as published by |
6 |
the Free Software Foundation; either version 2 of the License, or |
the Free Software Foundation; either version 2 of the License, or |
7 |
(at your option) any later version. |
(at your option) any later version. |
8 |
|
|
9 |
This program is distributed in the hope that it will be useful, |
GNU Radius is distributed in the hope that it will be useful, |
10 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
11 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
12 |
GNU General Public License for more details. |
GNU General Public License for more details. |
13 |
|
|
14 |
You should have received a copy of the GNU General Public License |
You should have received a copy of the GNU General Public License |
15 |
along with this program; if not, write to the Free Software Foundation, |
along with GNU Radius; if not, write to the Free Software Foundation, |
16 |
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ |
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ |
17 |
|
|
18 |
#ifdef HAVE_CONFIG_H |
#ifdef HAVE_CONFIG_H |
25 |
|
|
26 |
LOCK_DECLARE(lock) |
LOCK_DECLARE(lock) |
27 |
|
|
28 |
int |
static int |
29 |
store_passwd(pwd, result, buffer, buflen) |
store_passwd(struct passwd *pwd, struct passwd *result, char *buffer, |
30 |
struct passwd *pwd; |
int buflen) |
|
struct passwd *result; |
|
|
char *buffer; |
|
|
int buflen; |
|
31 |
{ |
{ |
32 |
int len; |
int len; |
33 |
|
|
53 |
struct passwd *pwd, char *buffer, int buflen); |
struct passwd *pwd, char *buffer, int buflen); |
54 |
*/ |
*/ |
55 |
struct passwd * |
struct passwd * |
56 |
rad_getpwnam_r(name, result, buffer, buflen) |
rad_getpwnam_r(const char *name, struct passwd *result, char *buffer, |
57 |
const char *name; |
int buflen) |
|
struct passwd *result; |
|
|
char *buffer; |
|
|
int buflen; |
|
58 |
{ |
{ |
59 |
struct passwd *pwd; |
struct passwd *pwd; |
60 |
LOCK_SET(lock); |
LOCK_SET(lock); |