Bug 459414 - debug info message not MI compliant
debug info message not MI compliant
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: gdb (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jan Kratochvil
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-08-18 13:40 EDT by Dodji Seketeli
Modified: 2008-09-10 03:04 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-09-10 03:04:29 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Fix. (1.42 KB, patch)
2008-08-19 12:53 EDT, Jan Kratochvil
no flags Details | Diff

  None (edit)
Description Dodji Seketeli 2008-08-18 13:40:03 EDT
Description of problem:

GDB when used with the MI interpreter outputs the following message, when the inferior is restarted after a new version of the image of the inferior is generated:

"Missing separate debuginfos, use: debuginfo-install gcc.i386 glib2.i386 glibc.i686 glibmm24.i386 libgtop2.i386 libselinux.i386 libsigc++20.i386 libxml2.i386 zlib.i386"

The problem with that string is that it does not comply with the GDB/MI format, so it breaks GDB/MI clients.

Basically, each line of the message should be preceded by a '~' character, then by a '"' character, and the line should be ended by the '\n"' string.


Version-Release number of selected component (if applicable):

gdb-6.8-17.fc9

How reproducible:

Allways.

Steps to Reproduce:

1. compile a program file foo.c into a program foo.
2. gdb --interpreter=mi2 foo
3. break main
4. -exec-run
5. in another shell, do: 
touch foo.c;
recompile foo.c into foo.
6.  the former gdb prompt, do:
-exec-run

Actual results:

The string:

'Missing separate debuginfos, use: debuginfo-install gcc.i386 glib2.i386 glibc.i686 glibmm24.i386 libgtop2.i386 libselinux.i386 libsigc++20.i386 libxml2.i386 zlib.i386'

Appears before the normal GDB/MI formatted messages, normally returned by GDB.


Expected results:

All the messages returned by GDB should be MI compliant, when GDB is using the MI interpreter.

Additional info:
Comment 1 Denys Vlasenko 2008-08-19 09:02:00 EDT
Reproduced
Comment 2 Denys Vlasenko 2008-08-19 09:48:27 EDT
http://www.redhat.com/archives/fedora-extras-commits/2008-March/msg03025.html - this is what added this message. The fix would be to use fprintf_filtered instead of bare printf.
Comment 3 Jan Kratochvil 2008-08-19 12:53:41 EDT
Created attachment 314563 [details]
Fix.

(In reply to comment #2)
> The fix would be to use fprintf_filtered instead of bare printf.

It works fine, thanks. (used _unfiltered for no paginating for these messages)

(gdb) 
-exec-run
^running
(gdb) 
~"Missing separate debuginfos, use: debuginfo-install gd.x86_64 libXpm.x86_64\n"
~"`/tmp/link' has changed; re-reading symbols.\n"
Comment 4 Fedora Update System 2008-08-23 16:02:25 EDT
gdb-6.8-18.fc9 has been submitted as an update for Fedora 9.
http://admin.fedoraproject.org/updates/gdb-6.8-18.fc9
Comment 5 Denys Vlasenko 2008-09-02 07:12:51 EDT
Ian, can I close this bug now?
Comment 6 Jan Kratochvil 2008-09-02 07:29:33 EDT
Denys,
I forgot / did not turn the Bug to MODIFIED after its CVS commit/build:

* Sat Aug 23 2008 Jan Kratochvil <jan.kratochvil@redhat.com> - 6.8-18
- Fix MI debuginfo print on reloaded exec, found by Denys Vlasenko (BZ 459414).

Still the Bug should get CLOSED automatically by Bodhi when the gdb-6.8-18.fc9 update gets shipped.  It is still `pending' as the Bodhi infrastructure is somehow suspended recently (possibly due to the recent RH/F security issue).
https://admin.fedoraproject.org/updates/gdb-6.8-18.fc9
Formerly the updates were shipping about in 1-3 days.
Comment 7 Fedora Update System 2008-09-10 03:04:26 EDT
gdb-6.8-18.fc9 has been pushed to the Fedora 9 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.