File tree 1 file changed +13
-0
lines changed
1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -226,6 +226,19 @@ pub const EAI = enum(c_int) {
226
226
_ ,
227
227
};
228
228
229
+ pub const passwd = extern struct {
230
+ pw_name : ? [* :0 ]const u8 , // username
231
+ pw_passwd : ? [* :0 ]const u8 , // user password
232
+ pw_uid : uid_t , // user ID
233
+ pw_gid : gid_t , // group ID
234
+ pw_gecos : ? [* :0 ]const u8 , // user information
235
+ pw_dir : ? [* :0 ]const u8 , // home directory
236
+ pw_shell : ? [* :0 ]const u8 , // shell program
237
+ };
238
+
239
+ pub extern "c" fn getpwnam (name : [* :0 ]const u8 ) ? * passwd ;
240
+ pub extern "c" fn getpwuid (uid : uid_t ) ? * passwd ;
241
+
229
242
pub extern "c" fn fallocate64 (fd : fd_t , mode : c_int , offset : off_t , len : off_t ) c_int ;
230
243
pub extern "c" fn fopen64 (noalias filename : [* :0 ]const u8 , noalias modes : [* :0 ]const u8 ) ? * FILE ;
231
244
pub extern "c" fn fstat64 (fd : fd_t , buf : * Stat ) c_int ;
You can’t perform that action at this time.
0 commit comments