int      rv        = -1;
int      rv        = -999;
int GetSharedFileCount(char *file){  HKEY     keyHandle = 0;  LONG     result;  DWORD    type      = REG_DWORD;  DWORD    valbuf    = 0;  DWORD    valbufsize;  int      rv        = -1;  valbufsize = sizeof(DWORD);  result     = RegOpenKeyEx(HKEY_LOCAL_MACHINE, KEY_SHARED_DLLS, 0, KEY_READ, &keyHandle);  if(ERROR_SUCCESS == result)  {    result = RegQueryValueEx(keyHandle, file, NULL, &type, (LPBYTE)&valbuf, (LPDWORD)&valbufsize);    if((ERROR_SUCCESS == result) && (type == REG_DWORD))      rv = valbuf;    RegCloseKey(keyHandle);  }  return(rv);}