diff mbox

[1/2] fix memset size when opening a file

Message ID 1391764884-3929-1-git-send-email-clg@fr.ibm.com
State New
Headers show

Commit Message

Cédric Le Goater Feb. 7, 2014, 9:21 a.m. UTC
Signed-off-by: Cédric Le Goater <clg@fr.ibm.com>
---
 second/file.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/second/file.c b/second/file.c
index 8412075689e0..cb79e7877282 100644
--- a/second/file.c
+++ b/second/file.c
@@ -667,7 +667,7 @@  int open_file(struct boot_fspec_t* spec, struct boot_file_t* file)
 {
      int result;
 
-     memset(file, 0, sizeof(struct boot_file_t*));
+     memset(file, 0, sizeof(*file));
      file->fs        = &fs_default;
 
      DEBUG_F("dev_path = %s\nfile_name = %s\npartition = %d\n",