From 9b8b47a3d2402224f2180150ce1d49419625fc41 Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Sat, 13 Mar 2004 21:00:52 +0000 Subject: [PATCH] empty-cell-name-fix-20040313 If the Registry contains a "Cell" entry which is the null string don't crash. Instead panic and log an appropriate error. --- src/WINNT/afsd/afsd_init.c | 2 +- src/WINNT/afsd/cm_config.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/WINNT/afsd/afsd_init.c b/src/WINNT/afsd/afsd_init.c index c1be190fb3..3e949be975 100644 --- a/src/WINNT/afsd/afsd_init.c +++ b/src/WINNT/afsd/afsd_init.c @@ -911,7 +911,7 @@ LONG __stdcall afsd_ExceptionFilter(EXCEPTION_POINTERS *ep) if (ep->ExceptionRecord->ExceptionCode == EXCEPTION_BREAKPOINT) { - afsi_log("\nEXCEPTION_BREAKPOINT - continue execition ...\n"); + afsi_log("\nEXCEPTION_BREAKPOINT - continue execution ...\n"); #ifdef _DEBUG if (allocRequestBrk) diff --git a/src/WINNT/afsd/cm_config.c b/src/WINNT/afsd/cm_config.c index 60105fc35e..6063b00ba7 100644 --- a/src/WINNT/afsd/cm_config.c +++ b/src/WINNT/afsd/cm_config.c @@ -489,7 +489,7 @@ long cm_GetRootCellName(char *cellNamep) code = RegQueryValueEx(parmKey, "Cell", NULL, NULL, cellNamep, &dummyLen); RegCloseKey (parmKey); - if (code != ERROR_SUCCESS) + if (code != ERROR_SUCCESS || cellNamep[0] == 0) return -1; return 0;