On Fri, Nov 18, 2016 at 09:19:44AM +0100, Christoph Hellwig wrote: > On Thu, Nov 17, 2016 at 01:27:07PM -0500, Brian Foster wrote: > > It just hit me that extnum_t is signed and xfs_iext_get_extent() checks > > for < 0, so that covers here and my similar previous few comments. I > > still think we should probably check it in context rather than bury the > > check in the caller (I'd prefer an assert). Just my .02. > > There are several callers that rely on xfs_iext_get_extent handling > negative extents with a NULL return - in fact one reason for the > exact prototype of the function is to cover out of bound indices > that happen during normal operation based on how we iterate over > the extent list. Fair enough. I'm not a fan of the approach in principle, but I'm less worried about it given that it's not an actual bug. Brian > -- > To unsubscribe from this list: send the line "unsubscribe linux-xfs" in > the body of a message to majordomo@xxxxxxxxxxxxxxx > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-xfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html