Use 'pgrep -o' instead of 'pidof -s' to get the PID of status bar

This commit is contained in:
Utkarsh Verma 2021-10-15 10:11:50 +05:30
parent e68f434944
commit e39062e543
No known key found for this signature in database
GPG Key ID: 817656CF818EFCCC

View File

@ -18,7 +18,7 @@ getstatusbarpid()
return statuspid;
}
}
if (!(fp = popen("pidof -s "STATUSBAR, "r")))
if (!(fp = popen("pgrep -o "STATUSBAR, "r")))
return -1;
fgets(buf, sizeof(buf), fp);
pclose(fp);