Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Startup Appspawn Lite
提交
455dd81b
S
Startup Appspawn Lite
项目概览
OpenHarmony
/
Startup Appspawn Lite
大约 1 年 前同步成功
通知
4
Star
43
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
S
Startup Appspawn Lite
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
455dd81b
编写于
7月 22, 2021
作者:
O
openharmony_ci
提交者:
Gitee
7月 22, 2021
浏览文件
操作
浏览文件
下载
差异文件
!20 静态检查修改
Merge pull request !20 from 熊磊/init0722
上级
c2b511ca
2e6af0ec
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
3 addition
and
6 deletion
+3
-6
services/src/appspawn_message.c
services/src/appspawn_message.c
+1
-1
services/src/appspawn_process.c
services/src/appspawn_process.c
+1
-4
services/src/appspawn_service.c
services/src/appspawn_service.c
+1
-1
未找到文件。
services/src/appspawn_message.c
浏览文件 @
455dd81b
...
...
@@ -80,7 +80,7 @@ static enum OHOSLiteErrorCode ReadStringItem(cJSON* strItem, char** buf, size_t
return
EC_NOMEMORY
;
}
if
(
strLength
>
0
&&
memcpy_s
(
bufTmp
,
strLength
+
1
,
strPtr
,
strLength
)
!=
EOK
)
{
if
(
strLength
>
0
&&
memcpy_s
(
bufTmp
,
strLength
,
strPtr
,
strLength
)
!=
EOK
)
{
free
(
bufTmp
);
bufTmp
=
NULL
;
return
EC_FAILURE
;
...
...
services/src/appspawn_process.c
浏览文件 @
455dd81b
...
...
@@ -150,9 +150,6 @@ pid_t CreateProcess(const MessageSt* msgSt)
#endif // OHOS_DEBUG
// set permissions
if
(
msgSt
->
caps
==
NULL
)
{
exit
(
0x7f
);
// 0x7f: user specified
}
if
(
SetPerms
(
msgSt
->
uID
,
msgSt
->
gID
,
msgSt
->
capsCnt
,
msgSt
->
caps
)
!=
0
)
{
HILOG_ERROR
(
HILOG_MODULE_HIVIEW
,
"[appspawn] sub-process %{public}s exit!"
,
msgSt
->
bundleName
);
exit
(
0x7f
);
// 0x7f: user specified
...
...
@@ -167,7 +164,7 @@ pid_t CreateProcess(const MessageSt* msgSt)
getpid
(),
errno
);
}
// 1s = 1000000000ns
long
timeUsed
=
(
tmEnd
.
tv_sec
-
tmStart
.
tv_sec
)
*
(
long
)
1000000000
+
(
tmEnd
.
tv_nsec
-
tmStart
.
tv_nsec
);
long
timeUsed
=
(
tmEnd
.
tv_sec
-
tmStart
.
tv_sec
)
*
1000000000L
+
(
tmEnd
.
tv_nsec
-
tmStart
.
tv_nsec
);
HILOG_INFO
(
HILOG_MODULE_HIVIEW
,
"[appspawn] sub-process, pid %{public}d, timeused %ld ns."
,
\
getpid
(),
timeUsed
);
#endif // OHOS_DEBUG
...
...
services/src/appspawn_service.c
浏览文件 @
455dd81b
...
...
@@ -161,7 +161,7 @@ static int Invoke(IServerProxy* iProxy, int funcId, void* origin, IpcIo* req, Ip
GetCurTime
(
&
tmEnd
);
// 1s = 1000000000ns
long
timeUsed
=
(
tmEnd
.
tv_sec
-
tmStart
.
tv_sec
)
*
(
long
)
1000000000
+
(
tmEnd
.
tv_nsec
-
tmStart
.
tv_nsec
);
long
timeUsed
=
(
tmEnd
.
tv_sec
-
tmStart
.
tv_sec
)
*
1000000000L
+
(
tmEnd
.
tv_nsec
-
tmStart
.
tv_nsec
);
HILOG_INFO
(
HILOG_MODULE_HIVIEW
,
"[appspawn] invoke, reply pid %{public}d, timeused %{public}ld ns."
,
\
newPid
,
timeUsed
);
#else
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录