Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit defd249d authored by Elliott Hughes's avatar Elliott Hughes
Browse files

toolbox ps: replace strcpy with snprintf.

Change-Id: I0fdf9a8d5ab15bcff06cca3f3e7024ab76b219d9
parent 3b9ba98e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -151,7 +151,7 @@ static int ps_line(int pid, int tid)
    if (pw == 0 || (display_flags & SHOW_NUMERIC_UID)) {
        snprintf(user, sizeof(user), "%d", (int)stats.st_uid);
    } else {
        strcpy(user, pw->pw_name);
        snprintf(user, sizeof(user), "%s", pw->pw_name);
    }

    if (ppid_filter != 0 && ppid != ppid_filter) {