Martin Diehl 2021-01-10 10:17:16 +01:00
parent fc7f919c23
commit 2b91bad53e
1 changed files with 1 additions and 1 deletions

View File

@ -43,7 +43,7 @@ void gethostname_c(char hostname[], int *stat){
void getusername_c(char username[], int *stat){
struct passwd *pw = getpwuid(geteuid());
struct passwd *pw = getpwuid(getuid());
if(pw && strlen(pw->pw_name) <= STRLEN){
strncpy(username,pw->pw_name,STRLEN+1);
*stat = 0;