[PATCH] readsector0: the length of the buffer wrong

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi,

The length of the buffer is 4096, not 4069 in sg_read().
 
---
libmultipath/checkers/readsector0.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libmultipath/checkers/readsector0.c b/libmultipath/checkers/readsector0.c
index 0550fb6..1c2a868 100644
--- a/libmultipath/checkers/readsector0.c
+++ b/libmultipath/checkers/readsector0.c
@@ -29,7 +29,7 @@ int libcheck_check (struct checker * c)
                 unsigned char sbuf[SENSE_BUFF_LEN];
                 int ret;

-                 ret = sg_read(c->fd, &buf[0], 4069, &sbuf[0],
+                 ret = sg_read(c->fd, &buf[0], 4096, &sbuf[0],
                                        SENSE_BUFF_LEN, c->timeout);

                 switch (ret)
--
1.9.1




--------------------------------------------------------
ZTE Information Security Notice: The information contained in this mail (and any attachment transmitted herewith) is privileged and confidential and is intended for the exclusive use of the addressee(s).  If you are not an intended recipient, any disclosure, reproduction, distribution or other dissemination or use of the information contained is strictly prohibited.  If you have received this mail in error, please delete it and notify us immediately.


--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel

[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux