2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-09-05 08:45:28 +00:00

Fix -Wshadow warnings.

This commit is contained in:
Todd C. Miller
2020-09-25 15:09:45 -06:00
parent 7eda22c729
commit 88dcdcd11d
24 changed files with 151 additions and 181 deletions

View File

@@ -268,7 +268,7 @@ done:
int
get_starttime(pid_t pid, struct timespec *starttime)
{
struct pst_status pstat;
struct pst_status pst;
int rc;
debug_decl(get_starttime, SUDOERS_DEBUG_UTIL);
@@ -277,9 +277,9 @@ get_starttime(pid_t pid, struct timespec *starttime)
* EOVERFLOW is not a fatal error for the fields we use.
* See the "EOVERFLOW Error" section of pstat_getvminfo(3).
*/
rc = pstat_getproc(&pstat, sizeof(pstat), 0, pid);
rc = pstat_getproc(&pst, sizeof(pst), 0, pid);
if (rc != -1 || errno == EOVERFLOW) {
starttime->tv_sec = pstat.pst_start;
starttime->tv_sec = pst.pst_start;
starttime->tv_nsec = 0;
sudo_debug_printf(SUDO_DEBUG_INFO,