Forward value of sector_size instead of its address in blkdev_get_physector_size
This commit is contained in:
parent
e5041e76f8
commit
b5456d1676
1 changed files with 3 additions and 1 deletions
|
@ -226,8 +226,10 @@ int blkdev_get_sector_size(int fd __attribute__((__unused__)), int *sector_size)
|
||||||
#ifdef BLKPBSZGET
|
#ifdef BLKPBSZGET
|
||||||
int blkdev_get_physector_size(int fd, int *sector_size)
|
int blkdev_get_physector_size(int fd, int *sector_size)
|
||||||
{
|
{
|
||||||
if (ioctl(fd, BLKPBSZGET, §or_size) >= 0)
|
if (ioctl(fd, BLKPBSZGET, sector_size) >= 0)
|
||||||
|
{
|
||||||
return 0;
|
return 0;
|
||||||
|
}
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue