BLKGETSIZE ioctl uses unsigned long, not long for the size parameter.
Thus the maximum supported device is 2 TB on 32 bit platforms instead of only 1 TB. (Logical change 1.277)edge.strict_endians
parent
9a18a4a5ed
commit
46f0709d29
|
@ -903,7 +903,7 @@ static s64 device_size_get(int fd)
|
|||
{
|
||||
s64 high, low;
|
||||
#ifdef BLKGETSIZE
|
||||
long size;
|
||||
unsigned long size;
|
||||
|
||||
if (ioctl(fd, BLKGETSIZE, &size) >= 0) {
|
||||
Dprintf("BLKGETSIZE nr 512 byte blocks = %ld (0x%ld)\n", size,
|
||||
|
|
Loading…
Reference in New Issue