This commit is contained in:
Edward Tomasz Napierala 2012-04-12 16:55:48 +00:00
parent 4b47ece986
commit 6ad07d53c2

View File

@ -882,8 +882,7 @@ updcsloc(time_t modtime, int fsi, int fso, unsigned int Nflag)
*/
if (sblock.fs_contigsumsize > 0) {
for (block = howmany(d % sblock.fs_fpg, sblock.fs_frag),
lcs = 0; lcs < sblock.fs_contigsumsize;
block++, lcs++) {
lcs = 0; lcs < sblock.fs_contigsumsize; block++, lcs++) {
if (isclr(cg_clustersfree(&acg), block))
break;
}
@ -924,8 +923,7 @@ updcsloc(time_t modtime, int fsi, int fso, unsigned int Nflag)
sblock.fs_cstotal.cs_nbfree++;
if (sblock.fs_contigsumsize > 0) {
setbit(cg_clustersfree(&acg),
(d % sblock.fs_fpg) /
sblock.fs_frag);
(d % sblock.fs_fpg) / sblock.fs_frag);
if (lcs < sblock.fs_contigsumsize) {
if (lcs)
cg_clustersum(&acg)[lcs]--;
@ -1026,8 +1024,7 @@ updcsloc(time_t modtime, int fsi, int fso, unsigned int Nflag)
* Allocate all fragments used by the cylinder summary in the
* last block.
*/
if (d <
sblock.fs_csaddr + (sblock.fs_cssize / sblock.fs_fsize)) {
if (d < sblock.fs_csaddr + (sblock.fs_cssize / sblock.fs_fsize)) {
for (; d - sblock.fs_csaddr <
sblock.fs_cssize/sblock.fs_fsize; d++) {
clrbit(cg_blksfree(&acg), d % sblock.fs_fpg);