|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Minios-devel] [UNIKRAFT PATCH 2/3] lib/posix-user: Add getgrnam stub
Hi, Mihai,
I'm going to move the WARN_STUBBED() line after the declaration of g__
in order to make it compliant with checkpatch.
Reviewed-by: Costin Lupu <costin.lupu@xxxxxxxxx>
On 10/27/19 10:15 PM, Mihai Pogonaru wrote:
> Signed-off-by: Mihai Pogonaru <pogonarumihai@xxxxxxxxx>
> ---
> lib/posix-user/exportsyms.uk | 1 +
> lib/posix-user/user.c | 12 ++++++++++++
> 2 files changed, 13 insertions(+)
>
> diff --git a/lib/posix-user/exportsyms.uk b/lib/posix-user/exportsyms.uk
> index 5a7a0a59..7b4d0ca6 100644
> --- a/lib/posix-user/exportsyms.uk
> +++ b/lib/posix-user/exportsyms.uk
> @@ -23,3 +23,4 @@ issetugid
> setregid
> setgroups
> initgroups
> +getgrnam
> diff --git a/lib/posix-user/user.c b/lib/posix-user/user.c
> index 4134d6b7..c019b8f3 100644
> --- a/lib/posix-user/user.c
> +++ b/lib/posix-user/user.c
> @@ -34,11 +34,13 @@
> */
>
> #include <unistd.h>
> +#include <grp.h>
> #include <pwd.h>
> #include <string.h>
> #include <sys/types.h>
> #include <uk/essentials.h>
> #include <uk/list.h>
> +#include <uk/print.h>
> #include <uk/user.h>
>
> static struct passwd_entry {
> @@ -220,3 +222,13 @@ int setgroups(size_t size __unused, const gid_t *list
> __unused)
> {
> return 0;
> }
> +
> +struct group *getgrnam(const char *name __unused)
> +{
> + WARN_STUBBED();
> + static struct group g__ = {
> + .gr_gid = 0
> + };
> +
> + return &g__;
> +}
>
_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |