Hi - > + // Make the prefetch cache spaces smaller than the normal > + // fd cache if rpm scanning is on. This is to not waste memory > + // since the prefetch cache isn't used when -R isn't specified > + // Set to 1/2 arbitrarily > + if ( scan_archives[".rpm"] == "cat" ) > + { > + if ( fdcache_prefetch_fds == 0 ) > + fdcache_prefetch_fds = fdcache_fds * .5; > + if ( fdcache_prefetch_mbs == 0 ) > + fdcache_prefetch_mbs = fdcache_mbs * .5; > + }
Yeah, something like that. It turns out that space for the prefetch cache is not used at all if RPM (and don't forget about other archive types!) is not in effect. So it's harmless to set those defaults unconditionally. How about a simpler: if ( fdcache_prefetch_fds == 0 ) fdcache_prefetch_fds = fdcache_fds * .5; if ( fdcache_prefetch_mbs == 0 ) fdcache_prefetch_mbs = fdcache_mbs * .5; - FChE