diff options
author | David Malcolm <dmalcolm@redhat.com> | 2013-11-20 20:00:33 +0000 |
---|---|---|
committer | David Malcolm <dmalcolm@gcc.gnu.org> | 2013-11-20 20:00:33 +0000 |
commit | 1fef36449e233448605e7812f4e2874baf05ce53 (patch) | |
tree | 2e2e8d65e2b0455920aeb8baf6493a18908914c2 /gcc/gdbhooks.py | |
parent | f9d3a450cc3d48d151029b044b33fc7a0f5dd95d (diff) | |
download | gcc-1fef36449e233448605e7812f4e2874baf05ce53.zip gcc-1fef36449e233448605e7812f4e2874baf05ce53.tar.gz gcc-1fef36449e233448605e7812f4e2874baf05ce53.tar.bz2 |
gdbhooks.py: fix prettyprinting of NULL vec<>*
* gdbhooks.py (VecPrinter.children): Don't attempt to iterate
the children of a NULL pointer.
From-SVN: r205139
Diffstat (limited to 'gcc/gdbhooks.py')
-rw-r--r-- | gcc/gdbhooks.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/gdbhooks.py b/gcc/gdbhooks.py index baccd6b..f0a925c 100644 --- a/gcc/gdbhooks.py +++ b/gcc/gdbhooks.py @@ -383,6 +383,8 @@ class VecPrinter: return '0x%x' % long(self.gdbval) def children (self): + if long(self.gdbval) == 0: + return m_vecpfx = self.gdbval['m_vecpfx'] m_num = m_vecpfx['m_num'] m_vecdata = self.gdbval['m_vecdata'] |