diff --git a/src/net.h b/src/net.h index 45a4a06ed..8674a82e7 100644 --- a/src/net.h +++ b/src/net.h @@ -42,5 +42,6 @@ enum { #define EKERB -2 #define ELDAP -3 +#define EHOME -4 int receive_one_message(int sock, struct sctp_meta *msg_meta, struct strbuf *msg); diff --git a/src/op-adduser.c b/src/op-adduser.c index 17f3602e2..90ab6aa6c 100644 --- a/src/op-adduser.c +++ b/src/op-adduser.c @@ -167,7 +167,10 @@ static int32_t addmember(Ceo__AddUser *in, Ceo__AddUserResponse *out) { response_message(out, 0, "successfully created ldap group"); if ((home_stat = ceo_create_home(homedir, id, id))) - notice("successfully created home directory for %s", in->username); + response_message(out, EHOME, "unable to create home directory for %s", in->username); + else + response_message(out, 0, "successfully created home directory"); + return krb_stat || user_stat || group_stat || home_stat; } @@ -205,7 +208,9 @@ static int32_t addclub(Ceo__AddUser *in, Ceo__AddUserResponse *out) { response_message(out, 0, "successfully created ldap sudoers"); if ((home_stat = ceo_create_home(homedir, id, id))) - notice("successfully created home directory for %s", in->username); + response_message(out, EHOME, "unable to create home directory for %s", in->username); + else + response_message(out, 0, "successfully created home directory"); return user_stat || group_stat || sudo_stat || home_stat; }