Date: Sun, 24 Aug 2014 17:02:27 +0000 (UTC) From: Mark Johnston <markj@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r270506 - head/lib/libproc Message-ID: <201408241702.s7OH2RGA016154@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: markj Date: Sun Aug 24 17:02:27 2014 New Revision: 270506 URL: http://svnweb.freebsd.org/changeset/base/270506 Log: Fix a bug in r265255: only return NULL if the requested map wasn't found. Submitted by: Luke Chang-Hsien Tsai <luke.tw@gmail.com> MFC after: 1 week Modified: head/lib/libproc/proc_sym.c Modified: head/lib/libproc/proc_sym.c ============================================================================== --- head/lib/libproc/proc_sym.c Sun Aug 24 16:40:31 2014 (r270505) +++ head/lib/libproc/proc_sym.c Sun Aug 24 17:02:27 2014 (r270506) @@ -121,10 +121,12 @@ proc_obj2map(struct proc_handle *p, cons break; } } - if (rdl == NULL && strcmp(objname, "a.out") == 0 && p->rdexec != NULL) - rdl = p->rdexec; - else - return (NULL); + if (rdl == NULL) { + if (strcmp(objname, "a.out") == 0 && p->rdexec != NULL) + rdl = p->rdexec; + else + return (NULL); + } if ((map = malloc(sizeof(*map))) == NULL) return (NULL);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201408241702.s7OH2RGA016154>