mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 23:07:35 +00:00
LibCore: Add Core::System wrappers for getspent() and getspnam()
This commit is contained in:
parent
7008f74214
commit
431bd069f0
2 changed files with 34 additions and 0 deletions
|
@ -22,6 +22,10 @@
|
|||
#include <time.h>
|
||||
#include <utime.h>
|
||||
|
||||
#ifndef AK_OS_BSD_GENERIC
|
||||
# include <shadow.h>
|
||||
#endif
|
||||
|
||||
namespace Core::System {
|
||||
|
||||
#ifdef __serenity__
|
||||
|
@ -35,6 +39,11 @@ ErrorOr<void> mount(int source_fd, StringView target, StringView fs_type, int fl
|
|||
ErrorOr<long> ptrace(int request, pid_t tid, void* address, void* data);
|
||||
#endif
|
||||
|
||||
#ifndef AK_OS_BSD_GENERIC
|
||||
ErrorOr<Optional<struct spwd>> getspent();
|
||||
ErrorOr<Optional<struct spwd>> getspnam(StringView name);
|
||||
#endif
|
||||
|
||||
#ifndef AK_OS_MACOS
|
||||
ErrorOr<int> accept4(int sockfd, struct sockaddr*, socklen_t*, int flags);
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue