diff --git a/src/afs/afs_daemons.c b/src/afs/afs_daemons.c index d60f8457d4..0149dcf3a3 100644 --- a/src/afs/afs_daemons.c +++ b/src/afs/afs_daemons.c @@ -201,10 +201,10 @@ afs_Daemon(void) if (afsd_dynamic_vcaches && (last5MinCheck + 300 < now)) { /* start with trying to drop us back to our base usage */ int anumber; - if (afs_maxvcount <= afs_cacheStats) - anumber = VCACHE_FREE; + if (afs_vcount <= afs_cacheStats) + anumber = VCACHE_FREE; else - anumber = VCACHE_FREE + (afs_maxvcount - afs_cacheStats); + anumber = VCACHE_FREE + (afs_vcount - afs_cacheStats); ObtainWriteLock(&afs_xvcache, 734); afs_ShakeLooseVCaches(anumber);