mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-03-01 13:26:47 +08:00
Use getpwuid_r instead of getpwuid
gdb/ChangeLog: 2019-11-11 Christian Biesinger <cbiesinger@google.com> * nat/linux-osdata.c (user_from_uid): Use getpwuid_r. Change-Id: I587359267f8963ef1da6ba0223a1525807a721de
This commit is contained in:
parent
fb092e09a2
commit
7b7b9424d3
@ -1,3 +1,7 @@
|
||||
2019-11-11 Christian Biesinger <cbiesinger@google.com>
|
||||
|
||||
* nat/linux-osdata.c (user_from_uid): Use getpwuid_r.
|
||||
|
||||
2019-11-10 Andrew Burgess <andrew.burgess@embecosm.com>
|
||||
|
||||
* python/py-symbol.c (gdbpy_lookup_static_symbols): New
|
||||
|
@ -205,7 +205,10 @@ commandline_from_pid (PID_T pid)
|
||||
static void
|
||||
user_from_uid (char *user, int maxlen, uid_t uid)
|
||||
{
|
||||
struct passwd *pwentry = getpwuid (uid);
|
||||
struct passwd *pwentry;
|
||||
char buf[1024];
|
||||
struct passwd pwd;
|
||||
getpwuid_r (uid, &pwd, buf, sizeof (buf), &pwentry);
|
||||
|
||||
if (pwentry)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user