File tree Expand file tree Collapse file tree 6 files changed +31
-15
lines changed Expand file tree Collapse file tree 6 files changed +31
-15
lines changed Original file line number Diff line number Diff line change @@ -164,7 +164,6 @@ libshadow_la_SOURCES = \
164
164
semanage.c \
165
165
setugid.c \
166
166
setupenv.c \
167
- sgetpwent.c \
168
167
sgetspent.c \
169
168
sgroupio.c \
170
169
sgroupio.h \
@@ -190,6 +189,8 @@ libshadow_la_SOURCES = \
190
189
shadow/gshadow/sgetsgent.h \
191
190
shadow/gshadow/sgrp.c \
192
191
shadow/gshadow/sgrp.h \
192
+ shadow/passwd/sgetpwent.c \
193
+ shadow/passwd/sgetpwent.h \
193
194
shadowio.c \
194
195
shadowio.h \
195
196
shadowlog.c \
Original file line number Diff line number Diff line change @@ -397,9 +397,6 @@ extern void setup (struct passwd *);
397
397
/* setupenv.c */
398
398
extern void setup_env (struct passwd * );
399
399
400
- /* sgetpwent.c */
401
- extern struct passwd * sgetpwent (const char * buf );
402
-
403
400
/* sgetspent.c */
404
401
#ifndef HAVE_SGETSPENT
405
402
extern struct spwd * sgetspent (const char * string );
Original file line number Diff line number Diff line change 18
18
#include "fields.h"
19
19
#include "prototypes.h"
20
20
#include "pwio.h"
21
+ #include "shadow/passwd/sgetpwent.h"
22
+
21
23
22
24
static /*@null@*/ /*@only@*/ void * passwd_dup (const void * ent )
23
25
{
Original file line number Diff line number Diff line change 1
- /*
2
- * SPDX-FileCopyrightText: 1989 - 1994, Julianne Frances Haugh
3
- * SPDX-FileCopyrightText: 1996 - 1998, Marek Michałkiewicz
4
- * SPDX-FileCopyrightText: 2003 - 2005, Tomasz Kłoczko
5
- * SPDX-FileCopyrightText: 2008 , Nicolas François
6
- *
7
- * SPDX-License-Identifier: BSD-3-Clause
8
- */
1
+ // SPDX-FileCopyrightText: 1989-1994, Julianne Frances Haugh
2
+ // SPDX-FileCopyrightText: 1996-1998, Marek Michałkiewicz
3
+ // SPDX-FileCopyrightText: 2003-2005, Tomasz Kłoczko
4
+ // SPDX-FileCopyrightText: 2008, Nicolas François
5
+ // SPDX-FileCopyrightText: 2024, Alejandro Colomar <[email protected] >
6
+ // SPDX-License-Identifier: BSD-3-Clause
7
+
9
8
10
9
#include <config.h>
11
10
12
- #ident "$Id$ "
11
+ #include "shadow/passwd/sgetpwent.h "
13
12
14
13
#include <pwd.h>
15
14
#include <stdio.h>
38
37
* performance reasons. I am going to come up with some conditional
39
38
* compilation glarp to improve on this in the future.
40
39
*/
40
+ // from-string get pasword entry
41
41
struct passwd *
42
42
sgetpwent (const char * s )
43
43
{
@@ -85,4 +85,3 @@ sgetpwent(const char *s)
85
85
86
86
return & pwent ;
87
87
}
88
-
Original file line number Diff line number Diff line change
1
+ // SPDX-FileCopyrightText: 2024, Alejandro Colomar <[email protected] >
2
+ // SPDX-License-Identifier: BSD-3-Clause
3
+
4
+
5
+ #ifndef SHADOW_INCLUDE_LIB_SHADOW_PASSWD_SGETPWENT_H_
6
+ #define SHADOW_INCLUDE_LIB_SHADOW_PASSWD_SGETPWENT_H_
7
+
8
+
9
+ #include <config.h>
10
+
11
+ #include <pwd.h>
12
+
13
+
14
+ struct passwd * sgetpwent (const char * s );
15
+
16
+
17
+ #endif // include guard
Original file line number Diff line number Diff line change @@ -56,10 +56,10 @@ lib/selinux.c
56
56
lib/semanage.c
57
57
lib/setugid.c
58
58
lib/setupenv.c
59
- lib/sgetpwent.c
60
59
lib/sgetspent.c
61
60
lib/sgroupio.c
62
61
lib/shadow/group/sgetgrent.c
62
+ lib/shadow/passwd/sgetpwent.c
63
63
lib/shadowio.c
64
64
lib/shadowmem.c
65
65
lib/shell.c
You can’t perform that action at this time.
0 commit comments