From: Jeffrey Altman Date: Sun, 30 Mar 2008 17:19:01 +0000 (+0000) Subject: windows-aklog-cross-cell-20080330 X-Git-Tag: openafs-devel-1_5_61~1158 X-Git-Url: https://git.openafs.org/?p=openafs.git;a=commitdiff_plain;h=99a29903c8b77e2e3260bf06d913367fadbc4fed windows-aklog-cross-cell-20080330 LICENSE MIT report the new ID after a successful cross cell registration --- diff --git a/src/WINNT/aklog/aklog.c b/src/WINNT/aklog/aklog.c index e5b6b88..237e599 100644 --- a/src/WINNT/aklog/aklog.c +++ b/src/WINNT/aklog/aklog.c @@ -239,9 +239,6 @@ void ViceIDToUsername(char *username, char *realm_of_user, char *realm_of_cell, static char confname[512] = { 0 }; char username_copy[BUFSIZ]; afs_int32 viceId; /* AFS uid of user */ -#ifdef ALLOW_REGISTER - afs_int32 id; -#endif /* ALLOW_REGISTER */ if (confname[0] == '\0') { strncpy(confname, AFSDIR_CLIENT_ETC_DIRPATH, sizeof(confname)); @@ -297,7 +294,6 @@ void ViceIDToUsername(char *username, char *realm_of_user, char *realm_of_cell, printf("doing first-time registration of %s " "at %s\n", username, cell_to_use); } - id = 0; strncpy(aclient->name, username, MAXKTCNAMELEN - 1); aclient->name[MAXKTCNAMELEN - 1] = '\0'; strcpy(aclient->instance, ""); @@ -331,7 +327,7 @@ void ViceIDToUsername(char *username, char *realm_of_user, char *realm_of_cell, /* copy the name because pr_CreateUser lowercases the realm */ strncpy(username_copy, username, BUFSIZ); - *status = pr_CreateUser(username, &id); + *status = pr_CreateUser(username, &viceId); /* and restore the name to the original state */ strncpy(username, username_copy, BUFSIZ);