Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
libvirt
提交
b0590a53
L
libvirt
项目概览
openeuler
/
libvirt
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
L
libvirt
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
b0590a53
编写于
8年前
作者:
J
Ján Tomko
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
test-wrap-argv: hold a copy of the original file in an array
This will be useful to check if the file is wrapped already.
上级
80880fd4
master
openEuler-20.03-LTS
openEuler-20.09
v2.0-maint
v2.1-maint
v2.2-maint
v3.0-maint
v3.2-maint
v3.7-maint
v4.1-maint
v4.10-maint
v4.2-maint
v4.3-maint
v4.4-maint
v4.5-maint
v4.6-maint
v4.7-maint
v4.8-maint
v4.9-maint
v5.0-maint
v5.1-maint
v5.1.0-maint
v5.2-maint
v5.3-maint
v6.5.0-rc2
v6.5.0-rc1
v6.4.0
v6.4.0-rc1
v6.3.0
v6.3.0-rc1
v6.2.0
v6.2.0-rc1
v6.1.0
v6.1.0-rc2
v6.1.0-rc1
v6.0.0
v6.0.0-rc2
v6.0.0-rc1
v5.10.0
v5.10.0-rc2
v5.10.0-rc1
v5.9.0
v5.9.0-rc1
v5.8.0
v5.8.0-rc2
v5.8.0-rc1
v5.7.0
v5.7.0-rc2
v5.7.0-rc1
v5.6.0
v5.6.0-rc2
v5.6.0-rc1
v5.5.0
v5.5.0-rc2
v5.5.0-rc1
v5.4.0
v5.4.0-rc2
v5.4.0-rc1
v5.3.0
v5.3.0-rc2
v5.3.0-rc1
v5.2.0
v5.2.0-rc2
v5.2.0-rc1
v5.1.0
v5.1.0-rc2
v5.1.0-rc1
v5.0.0
v5.0.0-rc2
v5.0.0-rc1
v4.10.0
v4.10.0-rc2
v4.10.0-rc1
v4.9.0
v4.9.0-rc1
v4.8.0
v4.8.0-rc2
v4.8.0-rc1
v4.7.0
v4.7.0-rc2
v4.7.0-rc1
v4.6.0
v4.6.0-rc2
v4.6.0-rc1
v4.5.0
v4.5.0-rc2
v4.5.0-rc1
v4.4.0
v4.4.0-rc2
v4.4.0-rc1
v4.3.0
v4.3.0-rc2
v4.3.0-rc1
v4.2.0
v4.2.0-rc2
v4.2.0-rc1
v4.1.0
v4.1.0-rc2
v4.1.0-rc1
v4.0.0
v4.0.0-rc2
v4.0.0-rc1
v3.10.0
v3.10.0-rc2
v3.10.0-rc1
v3.9.0
v3.9.0-rc2
v3.9.0-rc1
v3.8.0
v3.8.0-rc1
v3.7.0
v3.7.0-rc2
v3.7.0-rc1
v3.6.0
v3.6.0-rc2
v3.6.0-rc1
v3.5.0
v3.5.0-rc2
v3.5.0-rc1
v3.4.0
v3.4.0-rc2
v3.4.0-rc1
v3.3.0
v3.3.0-rc2
v3.3.0-rc1
v3.2.1
v3.2.0
v3.2.0-rc2
v3.2.0-rc1
v3.1.0
v3.1.0-rc2
v3.1.0-rc1
v3.0.0
v3.0.0-rc2
v3.0.0-rc1
v2.5.0
v2.5.0-rc2
v2.5.0-rc1
v2.4.0
v2.4.0-rc2
v2.4.0-rc1
v2.3.0
v2.3.0-rc2
v2.3.0-rc1
v2.2.1
v2.2.0
v2.2.0-rc2
v2.2.0-rc1
v2.1.0
v2.1.0-rc1
v2.0.0
v2.0.0-rc2
v2.0.0-rc1
CVE-2017-1000256
CVE-2017-2635
CVE-2016-5008
无相关合并请求
变更
1
显示空白变更内容
内联
并排
Showing
1 changed file
with
4 addition
and
5 deletion
+4
-5
tests/test-wrap-argv.pl
tests/test-wrap-argv.pl
+4
-5
未找到文件。
tests/test-wrap-argv.pl
浏览文件 @
b0590a53
...
@@ -33,15 +33,15 @@ sub rewrap {
...
@@ -33,15 +33,15 @@ sub rewrap {
# Read the original file
# Read the original file
open
FILE
,
"
<
",
$file
or
die
"
cannot read
$file
: $!
";
open
FILE
,
"
<
",
$file
or
die
"
cannot read
$file
: $!
";
my
@lines
;
my
@orig_lines
=
<
FILE
>
;
while
(
<
FILE
>
)
{
close
FILE
;
my
@lines
=
@orig_lines
;
foreach
(
@lines
)
{
# If there is a trailing '\' then kill the new line
# If there is a trailing '\' then kill the new line
if
(
/\\$/
)
{
if
(
/\\$/
)
{
chomp
;
chomp
;
$_
=~
s/\\$//
;
$_
=~
s/\\$//
;
}
}
push
@lines
,
$_
;
}
}
# Skip empty files
# Skip empty files
...
@@ -49,7 +49,6 @@ sub rewrap {
...
@@ -49,7 +49,6 @@ sub rewrap {
# Kill the last new line in the file
# Kill the last new line in the file
chomp
@lines
[
$#lines
];
chomp
@lines
[
$#lines
];
close
FILE
;
# Reconstruct the master data by joining all lines
# Reconstruct the master data by joining all lines
# and then split again based on the real desired
# and then split again based on the real desired
...
...
This diff is collapsed.
Click to expand it.
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录
反馈
建议
客服
返回
顶部