mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-27 17:52:43 +00:00
fs/msdosfs fatblock: use ulmin() rather than min()
PR: 277237
(cherry picked from commit 0085afdceb
)
This commit is contained in:
parent
a60220bbb5
commit
846bf43ca4
@ -97,7 +97,7 @@ fatblock(struct msdosfsmount *pmp, u_long ofs, u_long *bnp, u_long *sizep,
|
|||||||
fatblocksec /= 2;
|
fatblocksec /= 2;
|
||||||
}
|
}
|
||||||
bn = ofs / pmp->pm_fatblocksize * pmp->pm_fatblocksec;
|
bn = ofs / pmp->pm_fatblocksize * pmp->pm_fatblocksec;
|
||||||
size = roundup(min(fatblocksec, pmp->pm_FATsecs - bn) * DEV_BSIZE,
|
size = roundup(ulmin(fatblocksec, pmp->pm_FATsecs - bn) * DEV_BSIZE,
|
||||||
pmp->pm_BlkPerSec * DEV_BSIZE);
|
pmp->pm_BlkPerSec * DEV_BSIZE);
|
||||||
bn += pmp->pm_fatblk + pmp->pm_curfat * pmp->pm_FATsecs;
|
bn += pmp->pm_fatblk + pmp->pm_curfat * pmp->pm_FATsecs;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user