Windows: buf_SetDirty do nothing if length is zero

Change-Id: Id6a96feadccc437900e944ab23b45d2717766e1c
Reviewed-on: http://gerrit.openafs.org/5358
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
Tested-by: Jeffrey Altman <jaltman@openafs.org>
This commit is contained in:
Jeffrey Altman 2011-09-01 09:51:06 -04:00 committed by Jeffrey Altman
parent abe0e6b7bc
commit 7dcc476637

View File

@ -1351,6 +1351,9 @@ void buf_SetDirty(cm_buf_t *bp, afs_uint32 offset, afs_uint32 length, cm_user_t
osi_assertx(bp->magic == CM_BUF_MAGIC, "invalid cm_buf_t magic");
osi_assertx(bp->refCount > 0, "cm_buf_t refcount 0");
if (length == 0)
return;
if (bp->flags & CM_BUF_DIRTY) {
osi_Log1(buf_logp, "buf_SetDirty 0x%p already dirty", bp);