提交 8bb91942 编写于 作者: C chengjinsong2

修改增量编译错误

Signed-off-by: Nchengjinsong2 <chengjinsong2@huawei.com>
上级 d5610159
......@@ -67,7 +67,7 @@ def fix_para_file(options):
if options.extra:
parse_extra_params(options.extra, contents)
flags = os.O_WRONLY | os.O_CREAT
flags = os.O_WRONLY | os.O_CREAT | os.O_TRUNC
modes = stat.S_IWUSR | stat.S_IRUSR | stat.S_IWGRP | stat.S_IRGRP
with os.fdopen(os.open(options.output, flags, modes), 'w') as f:
for key in contents:
......
......@@ -837,7 +837,7 @@ class SeccompPolicyParser:
' ' + '\n '.join(self.bpf_generator.bpf_policy) + footer
flags = os.O_WRONLY | os.O_CREAT
flags = os.O_WRONLY | os.O_CREAT | os.O_TRUNC
modes = stat.S_IWUSR | stat.S_IRUSR | stat.S_IWGRP | stat.S_IRGRP
with os.fdopen(os.open(args.dstfile, flags, modes), 'w') as output_file:
output_file.write(content)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册