All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] nvme-cli: adjust memset size for data buffer in submit_io
@ 2018-07-03 13:18 Minwoo Im
  2018-07-03 14:25 ` Keith Busch
  0 siblings, 1 reply; 2+ messages in thread
From: Minwoo Im @ 2018-07-03 13:18 UTC (permalink / raw)


Adjust size of memset() for the data buffer to its own size.

Signed-off-by: Minwoo Im <minwoo.im.dev at gmail.com>
---
 nvme.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/nvme.c b/nvme.c
index e2f8752..039997a 100644
--- a/nvme.c
+++ b/nvme.c
@@ -3942,7 +3942,7 @@ static int submit_io(int opcode, char *command, const char *desc,
 		err = ENOMEM;
 		goto close_mfd;
 	}
-	memset(buffer, 0, cfg.data_size);
+	memset(buffer, 0, buffer_size);
 
 	if (cfg.metadata_size) {
 		mbuffer = malloc(cfg.metadata_size);
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [PATCH] nvme-cli: adjust memset size for data buffer in submit_io
  2018-07-03 13:18 [PATCH] nvme-cli: adjust memset size for data buffer in submit_io Minwoo Im
@ 2018-07-03 14:25 ` Keith Busch
  0 siblings, 0 replies; 2+ messages in thread
From: Keith Busch @ 2018-07-03 14:25 UTC (permalink / raw)


Applied, thanks

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-07-03 14:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-03 13:18 [PATCH] nvme-cli: adjust memset size for data buffer in submit_io Minwoo Im
2018-07-03 14:25 ` Keith Busch

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.