question about fs/ceph/snap.c
The file fs/ceph/snap.c contains four calls to ceph_lookup_snap_realm, all of which test the returned value first with IS_ERR and then by checking for a NULL pointer. But the definition of ceph_lookup_snap_realm contains a dereference of its argument if it is not NULL, which suggests that an ERR_PTR value is not what expected. So something seems to be inconsistent here.
julia
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july
Quoted 6 lines · Julia Lawall
The file
fs/ceph/snap.ccontains four calls toceph_lookup_snap_realm, all of which test the returned value first withIS_ERRand then by checking for a NULL pointer. But the definition ofceph_lookup_snap_realmcontains a dereference of its argument if it is not NULL, which suggests that anERR_PTRvalue is not what expected. So something seems to be inconsistent here.
Yeah, I'm not sure how it ended up that way. I'll just remove the IS_ERR() checks, since there are no errors the lookup can return (besides not found).
The other patches look good; applying them now. Thank you! Coccinelle is pretty slick. :)
sage
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july