system/lzf: correct the open mode
Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
parent
419e6b012a
commit
fcd69d1cdf
@ -311,7 +311,6 @@ short_read:
|
|||||||
|
|
||||||
static int open_out(FAR const char *name)
|
static int open_out(FAR const char *name)
|
||||||
{
|
{
|
||||||
int fd;
|
|
||||||
int m = O_EXCL;
|
int m = O_EXCL;
|
||||||
|
|
||||||
if (g_force)
|
if (g_force)
|
||||||
@ -319,8 +318,7 @@ static int open_out(FAR const char *name)
|
|||||||
m = 0;
|
m = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
fd = open(name, O_CREAT | O_WRONLY | O_TRUNC | m, 600);
|
return open(name, O_CREAT | O_WRONLY | O_TRUNC | m, 0600);
|
||||||
return fd;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int compose_name(FAR const char *fname, FAR char *oname, int namelen)
|
static int compose_name(FAR const char *fname, FAR char *oname, int namelen)
|
||||||
|
Loading…
Reference in New Issue
Block a user