creat(2) expects a creation mode parameter, not an open flag
PATCH 1/1 creat(2) expects a creation mode parameter, not an open flag
Signed-off-by Ferenc Wagner <[email protected]>
--- mtd_debug.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
mtd_debug.c +1 -1
@@ -110,7 +110,7 @@ int flash_to_file (int fd,u_int32_t offset,size_t len,const char *filename)perror ("lseek()" ); goto err0; } - outfd =creat (filename,O_WRONLY ); + outfd =creat (filename,0666 );if (outfd <0 ) {perror ("creat()" );
Signature · 1 line
1.5.6.5
Artem Bityutskiy
AppliedQuoted 1 line · Ferenc Wagner
creat(2) expects a creation mode parameter, not an open flag
Pushed to the mtd-utils tree, thanks.
Signature · 2 lines
Best Regards, Artem Bityutskiy (Артём Битюцкий)