Bug 504356 - gdb display some Python error when displaying some C++ objects
Summary: gdb display some Python error when displaying some C++ objects
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: gdb
Version: 11
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Jan Kratochvil
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-06-05 19:03 UTC by Hubert Figuiere
Modified: 2009-06-18 11:51 UTC (History)
4 users (show)

Fixed In Version: 6.8.50.20090302-27.fc11
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-06-18 11:51:48 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
patch for python printer (717 bytes, patch)
2009-06-08 21:24 UTC, Tom Tromey
no flags Details | Diff

Description Hubert Figuiere 2009-06-05 19:03:02 UTC
gdb display some Python error when displaying some C++ objects

Here is ONE example albeit not the only.

$ p trie
$15 = {_vptr.TrieTree = 0x8093040, m_root = warning: RTTI symbol not found for class 'std::tr1::_Sp_counted_base_impl<gnote::TrieTree<std::string>::TrieState*, std::tr1::_Sp_deleter<gnote::TrieTree<std::string>::TrieState>, (__gnu_cxx::_Lock_policy)2>'
std::shared_ptr (count 4) 0x80a7440, m_fail_states = std::vector of length 8, capacity 8 = {warning: RTTI symbol not found for class 'std::tr1::_Sp_counted_base_impl<gnote::TrieTree<std::string>::TrieState*, std::tr1::_Sp_deleter<gnote::TrieTree<std::string>::TrieState>, (__gnu_cxx::_Lock_policy)2>'
std::shared_ptr (count 2) 0x80a74f8, warning: RTTI symbol not found for class 'std::tr1::_Sp_counted_base_impl<gnote::TrieTree<std::string>::TrieState*, std::tr1::_Sp_deleter<gnote::TrieTree<std::string>::TrieState>, (__gnu_cxx::_Lock_policy)2>'

std::shared_ptr (count 2) 0x80a7568, warning: RTTI symbol not found for class 'std::tr1::_Sp_counted_base_impl<gnote::TrieTree<std::string>::TrieState*, std::tr1::_Sp_deleter<gnote::TrieTree<std::string>::TrieState>, (__gnu_cxx::_Lock_policy)2>'
std::shared_ptr (count 2) 0x80a75d8, Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/gdb/libstdcxx/v6/printers.py", line 32, in to_string
    self.val['_M_ptr'])
TypeError: %d format: a number is required, not gdb.Value
, Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/gdb/libstdcxx/v6/printers.py", line 32, in to_string
    self.val['_M_ptr'])
TypeError: %d format: a number is required, not gdb.Value
, Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/gdb/libstdcxx/v6/printers.py", line 32, in to_string
    self.val['_M_ptr'])
TypeError: %d format: a number is required, not gdb.Value
, Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/gdb/libstdcxx/v6/printers.py", line 32, in to_string
    self.val['_M_ptr'])
TypeError: %d format: a number is required, not gdb.Value
, Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/gdb/libstdcxx/v6/printers.py", line 32, in to_string
    self.val['_M_ptr'])
TypeError: %d format: a number is required, not gdb.Value
}, m_case_sensitive = false, m_max_length = 3}

Comment 1 Tom Tromey 2009-06-05 20:47:47 UTC
I'm looking into the printer bug.
Jan, I'll send a patch when it is ready.
Or, I can check it in to a branch if you'd prefer, just let me know.

Comment 2 Jan Kratochvil 2009-06-05 21:02:32 UTC
(In reply to comment #1)
> Or, I can check it in to a branch if you'd prefer, just let me know.  

Thanks, either way, not sure how alive the archer branch is since it is now in FSF GDB.

Comment 3 Tom Tromey 2009-06-08 21:24:42 UTC
Created attachment 346935 [details]
patch for python printer

This turned out to be a bug already fixed in the latest
libstdc++ printers.  I'm attaching a patch I made against
the SRPM gdb-6.8.50.20090302.  I didn't update the .spec
file, sorry.

I compared the SRPM's printers with the latest and the other
differences are very minor.

Hubert, if you know of other printer bugs, please report them,
and I will fix them ASAP.  Thanks.

Comment 4 Fedora Update System 2009-06-09 16:10:05 UTC
gdb-6.8.50.20090302-24.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/gdb-6.8.50.20090302-24.fc11

Comment 5 Fedora Update System 2009-06-15 13:14:07 UTC
gdb-6.8.50.20090302-27.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/gdb-6.8.50.20090302-27.fc11

Comment 6 Fedora Update System 2009-06-18 11:51:33 UTC
gdb-6.8.50.20090302-27.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.