On 03/18/2014 06:24 AM, [email protected] wrote: > From: ChenLiang <[email protected]> > > Rebuild the cache_is_cached function by cache_get_by_addr. > > Signed-off-by: ChenLiang <[email protected]> > Signed-off-by: Gonglei <[email protected]> > --- > page_cache.c | 38 ++++++++++++++++---------------------- > 1 file changed, 16 insertions(+), 22 deletions(-) >
> int cache_insert(PageCache *cache, uint64_t addr, const uint8_t *pdata,
> uint64_t current_age)
> {
>
> - CacheItem *it = NULL;
> -
> - g_assert(cache);
> - g_assert(cache->page_cache);
> + CacheItem *it;
Why are you dropping the asserts?
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
