mCurRegFile = nsnull;
if (mCurRegFile) nsCRT::free(mCurRegFile); mCurRegFile = NULL;
NS_IMETHODIMP nsRegistry::Close() {    REGERR err = REGERR_OK;    if( mReg ) {        PR_Lock(mregLock);        err = NR_RegClose( mReg );        PR_Unlock(mregLock);        mReg = 0;        mCurRegFile = nsnull;        mCurRegID = 0;    }    return regerr2nsresult( err );}