HWC screencap portability improvement
Summary: Removing the only reference to the hardcoded full unix path of screencap.
This will help with portability.
Test: Successful Build on master branch
Change-Id: I8cb83cf312c5dea6f2688864b84145d8eb47be3d
Signed-off-by: Abdelrahman Daim <adaim@meta.com>
diff --git a/cmds/dumpstate/dumpstate.cpp b/cmds/dumpstate/dumpstate.cpp
index 1e5dd97..24b4b0d 100644
--- a/cmds/dumpstate/dumpstate.cpp
+++ b/cmds/dumpstate/dumpstate.cpp
@@ -4608,7 +4608,7 @@
void Dumpstate::TakeScreenshot(const std::string& path) {
const std::string& real_path = path.empty() ? screenshot_path_ : path;
int status =
- RunCommand("", {"/system/bin/screencap", "-p", real_path},
+ RunCommand("", {"screencap", "-p", real_path},
CommandOptions::WithTimeout(10).Always().DropRoot().RedirectStderr().Build());
if (status == 0) {
MYLOGD("Screenshot saved on %s\n", real_path.c_str());