Properly cast longs to off_t so we dont loose precision.

This commit is contained in:
Søren Schmidt 2003-09-16 14:41:44 +00:00
parent 979af4e167
commit 77de5988d6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=120126

View File

@ -1034,7 +1034,7 @@ acd_ioctl(dev_t dev, u_long cmd, caddr_t addr, int flags, struct thread *td)
break;
case DIOCGMEDIASIZE:
*(off_t *)addr = cdp->disk_size * cdp->block_size;
*(off_t *)addr = (off_t)cdp->disk_size * (off_t)cdp->block_size;
break;
case DIOCGSECTORSIZE: