Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 300907
Collapse All | Expand All

(-)a/fs/xfs/xfs_dir2_leaf.c (-1 / +3 lines)
Lines 854-859 xfs_dir2_leaf_getdents( Link Here
854
			 */
854
			 */
855
			ra_want = howmany(bufsize + mp->m_dirblksize,
855
			ra_want = howmany(bufsize + mp->m_dirblksize,
856
					  mp->m_sb.sb_blocksize) - 1;
856
					  mp->m_sb.sb_blocksize) - 1;
857
			ASSERT(ra_want >= 0);
857
858
858
			/*
859
			/*
859
			 * If we don't have as many as we want, and we haven't
860
			 * If we don't have as many as we want, and we haven't
Lines 1088-1094 xfs_dir2_leaf_getdents( Link Here
1088
		 */
1089
		 */
1089
		ptr += length;
1090
		ptr += length;
1090
		curoff += length;
1091
		curoff += length;
1091
		bufsize -= length;
1092
		/* bufsize may have just been a guess; don't go negative */
1093
		bufsize = bufsize > length ? bufsize - length : 0;
1092
	}
1094
	}
1093
1095
1094
	/*
1096
	/*

Return to bug 300907