소스 검색

fixed username function (wtf happened here?)

master
Aaron Marcher 8 년 전
committed by Aaron Marcher (drkhsh)
부모
커밋
545f1560e6
1개의 변경된 파일5개의 추가작업 그리고 4개의 파일을 삭제
  1. +5
    -4
      slstatus.c

+ 5
- 4
slstatus.c 파일 보기

@@ -455,11 +455,12 @@ username(void)
uid_t uid = geteuid();
struct passwd *pw = getpwuid(uid);

if (pw == NULL)
return smprintf("%s", pw->pw_name);
if (pw == NULL) {
warn("Could not get username");
return smprintf(UNKNOWN_STR);
}

warn("Could not get username");
return smprintf(UNKNOWN_STR);
return smprintf("%s", pw->pw_name);
}

static char *


불러오는 중...
취소
저장