mirror of
https://git.openafs.org/openafs.git
synced 2025-01-19 15:30:14 +00:00
windows-getrootcellname-20090223
LICENSE MIT do not mix and match CELL_MAXNAMELEN and MAXCELLCHARS. They are not the same.
This commit is contained in:
parent
f83cfcafcb
commit
80faa5e93d
@ -447,7 +447,7 @@ KFW_initialize(void)
|
||||
LoadFuncs(CCAPI_DLL, ccapi_fi, &hCCAPI, 0, 1, 0, 0);
|
||||
|
||||
if ( KFW_is_available() ) {
|
||||
char rootcell[MAXCELLCHARS+1];
|
||||
char rootcell[CELL_MAXNAMELEN+1];
|
||||
#ifdef USE_MS2MIT
|
||||
KFW_import_windows_lsa();
|
||||
#endif /* USE_MS2MIT */
|
||||
|
@ -394,7 +394,10 @@ long cm_GetCellServDB(char *cellNamep, afs_uint32 len)
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* look up the root cell's name in the Registry */
|
||||
/* look up the root cell's name in the Registry
|
||||
* Input buffer must be at least CELL_MAXNAMELEN
|
||||
* in size. (Defined in cm_cell.h)
|
||||
*/
|
||||
long cm_GetRootCellName(char *cellNamep)
|
||||
{
|
||||
DWORD code, dummyLen;
|
||||
@ -405,7 +408,7 @@ long cm_GetRootCellName(char *cellNamep)
|
||||
if (code != ERROR_SUCCESS)
|
||||
return -1;
|
||||
|
||||
dummyLen = 256;
|
||||
dummyLen = CELL_MAXNAMELEN;
|
||||
code = RegQueryValueEx(parmKey, "Cell", NULL, NULL,
|
||||
cellNamep, &dummyLen);
|
||||
RegCloseKey (parmKey);
|
||||
|
Loading…
Reference in New Issue
Block a user