fd->secret->lockCount == -1;
fd->secret->lockCount = -1;
PR_IMPLEMENT(PRStatus) PR_LockFile(PRFileDesc *fd){    PRStatus status = PR_SUCCESS;#ifdef WINNT    if (!fd->secret->md.io_model_committed) {        PRInt32 rv;        rv = _md_Associate((HANDLE)fd->secret->md.osfd);        PR_ASSERT(0 != rv);        fd->secret->md.io_model_committed = PR_TRUE;    }#endif    PR_Lock(_pr_flock_lock);    while (fd->secret->lockCount == -1)        PR_WaitCondVar(_pr_flock_cv, PR_INTERVAL_NO_TIMEOUT);    if (fd->secret->lockCount == 0) {        fd->secret->lockCount == -1;        PR_Unlock(_pr_flock_lock);        status = _PR_MD_LOCKFILE(fd->secret->md.osfd);        PR_Lock(_pr_flock_lock);        fd->secret->lockCount = (status == PR_SUCCESS) ? 1 : 0;        PR_NotifyAllCondVar(_pr_flock_cv);    } else {        fd->secret->lockCount++;    }    PR_Unlock(_pr_flock_lock);     return status;}