semanage.c \
setugid.c \
setupenv.c \
- sgetgrent.c \
sgetpwent.c \
sgetspent.c \
sgroupio.c \
sgroupio.h \
+ shadow/group/sgetgrent.c \
+ shadow/group/sgetgrent.h \
shadow/grp/agetgroups.c \
shadow/grp/agetgroups.h \
shadow/gshadow/endsgent.c \
#include "getdef.h"
#include "groupio.h"
#include "prototypes.h"
+#include "shadow/group/sgetgrent.h"
#include "string/sprintf/aprintf.h"
#include "string/strcmp/streq.h"
/* setupenv.c */
extern void setup_env (struct passwd *);
-/* sgetgrent.c */
-extern struct group *sgetgrent (const char *buf);
-
/* sgetpwent.c */
extern struct passwd *sgetpwent (const char *buf);
-/*
- * SPDX-FileCopyrightText: 1990 - 1994, Julianne Frances Haugh
- * SPDX-FileCopyrightText: 1996 - 1998, Marek Michałkiewicz
- * SPDX-FileCopyrightText: 2005 , Tomasz Kłoczko
- * SPDX-FileCopyrightText: 2008 , Nicolas François
- *
- * SPDX-License-Identifier: BSD-3-Clause
- */
+// SPDX-FileCopyrightText: 1990-1994, Julianne Frances Haugh
+// SPDX-FileCopyrightText: 1996-1998, Marek Michałkiewicz
+// SPDX-FileCopyrightText: 2005, Tomasz Kłoczko
+// SPDX-FileCopyrightText: 2008, Nicolas François
+// SPDX-FileCopyrightText: 2024, Alejandro Colomar <alx@kernel.org>
+// SPDX-License-Identifier: BSD-3-Clause
+
#include "config.h"
-#ident "$Id$"
+#include "shadow/group/sgetgrent.h"
#include <grp.h>
#include <stdio.h>
}
+// from-string get group entry
struct group *
sgetgrent(const char *s)
{
--- /dev/null
+// SPDX-FileCopyrightText: 2024, Alejandro Colomar <alx@kernel.org>
+// SPDX-License-Identifier: BSD-3-Clause
+
+
+#ifndef SHADOW_INCLUDE_LIB_SHADOW_GROUP_SGETGRENT_H_
+#define SHADOW_INCLUDE_LIB_SHADOW_GROUP_SGETGRENT_H_
+
+
+#include "config.h"
+
+#include <grp.h>
+
+
+struct group *sgetgrent(const char *s);
+
+
+#endif // include guard