From: Dongwoo Lee Date: Mon, 21 Feb 2022 07:22:01 +0000 (+0900) Subject: resource: process: Handle pid, tgid into parsing nla types X-Git-Tag: accepted/tizen/unified/20220302.131908~11 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=12f899171da9cc06f84a29ed074f11e0285c507a;p=platform%2Fcore%2Fsystem%2Fpass.git resource: process: Handle pid, tgid into parsing nla types To prevent pid, tgid is considered error case, add handling of them. Change-Id: I3ef127312e860f8bf625a8427d5e40cfb68196cc Signed-off-by: Dongwoo Lee --- diff --git a/src/resource/resource-process.c b/src/resource/resource-process.c index acdb542..aff58e1 100644 --- a/src/resource/resource-process.c +++ b/src/resource/resource-process.c @@ -234,6 +234,9 @@ static int parse_aggregate_task_stats(struct nlattr *attr, int attr_size, { nla_for_each_attr(attr, attr, attr_size, attr_size) { switch (attr->nla_type) { + case TASKSTATS_TYPE_PID: + case TASKSTATS_TYPE_TGID: + break; case TASKSTATS_TYPE_STATS: nla_memcpy(stats, attr, sizeof(struct taskstats)); break;