Check process group ID for getting appid and pkgid 30/286630/1
authorHwankyu Jhun <h.jhun@samsung.com>
Tue, 10 Jan 2023 23:56:50 +0000 (23:56 +0000)
committerHwankyu Jhun <h.jhun@samsung.com>
Wed, 11 Jan 2023 00:00:21 +0000 (00:00 +0000)
commitcb999ca1c42406ab131399bdcd7135b0745dfdf1
treecd2dc33fa2103033220876678ec3f309996c5fbc
parente758912abe20154a2630d54e4f227c28d43b76fe
Check process group ID for getting appid and pkgid

The web engine is running as a child process of the web app.
If the web engine calls AUL APIs, the request is delivered to AMD.
Because, the process ID is not equal to the web app.
After this patch is applied, AUL API checks whether the process group ID
is equal to the process ID or not. Before executing an application,
the child process of the launchpad-process-pool calls the setsid() to
run the process in a new session. In that time, the process group is separated
from the launchpad-process-pool. Checking the process group ID can reduce
the IPC between AMD and the caller process.

Change-Id: I3746046c36328ecacc27c6cda16afbe44c1e1cfd
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
src/pkginfo.cc