Fix zombie process issue caused by trace trigger

Add waitpid() to allow system to release the resource associated with the child.

Bug: 308344874
Test: No zombie process found with "$ps -A | grep trigger_perf" and no
app crash observed.
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:7a295ee33f794c443cbb8eb255dcb1caef45898f)
Merged-In: Ie8fe67a14034149dbebddf7931bc2e1d2f12d1fe
Change-Id: Ie8fe67a14034149dbebddf7931bc2e1d2f12d1fe
1 file changed