Fix file permissions for nand sim backing file
authorCharles Manning <cdhmanning@gmail.com>
Tue, 7 May 2013 05:05:02 +0000 (17:05 +1200)
committerCharles Manning <cdhmanning@gmail.com>
Tue, 7 May 2013 05:05:02 +0000 (17:05 +1200)
Signed-off-by: Charles Manning <cdhmanning@gmail.com>
direct/test-framework/nandstore_file.c

index 1b9b70b..0b46b3e 100644 (file)
@@ -165,7 +165,7 @@ nandstore_file_init(const char *fname,
 
        strncpy(nsfp->backing_file, fname, sizeof(nsfp->backing_file));
 
-       nsfp->handle = open(nsfp->backing_file, O_RDWR | O_CREAT);
+       nsfp->handle = open(nsfp->backing_file, O_RDWR | O_CREAT, 0666);
        if(nsfp->handle >=0){
                fsize = lseek(nsfp->handle,0,SEEK_END);
                nbytes = ns->blocks * ns->pages_per_block *