Bug 195779 - MIExecReturn invokes exec-run instead of exec-return
Summary: MIExecReturn invokes exec-run instead of exec-return
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug (show other bugs)
Version: 4.0   Edit
Hardware: All Linux
: P3 normal (vote)
Target Milestone: 4.0.1   Edit
Assignee: Doug Schaefer CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks:
 
Reported: 2007-07-08 19:00 EDT by Ewa Matejska CLA
Modified: 2008-06-22 02:05 EDT (History)
1 user (show)

See Also:


Attachments
patch (616 bytes, patch)
2007-07-08 19:01 EDT, Ewa Matejska CLA
bjorn.freeman-benson: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ewa Matejska CLA 2007-07-08 19:00:24 EDT
Hi,

It seems that the class MIExecReturn incorrectly invokes exec-run instead of exec-return in following piece of code:

--------
public MIExecReturn(String miVersion, String arg) {
		super(miVersion, "-exec-run", new String[] { arg }); //$NON-NLS-1$
	}
--------

Patch attached.

Ewa.
Comment 1 Ewa Matejska CLA 2007-07-08 19:01:35 EDT
Created attachment 73283 [details]
patch
Comment 2 Doug Schaefer CLA 2007-08-28 13:15:07 EDT
Ouch. I'm wondering why we haven't seen bad behavior as a result of this. Or have we?
Comment 3 Ewa Matejska CLA 2007-08-28 14:20:57 EDT
I think the reason is that the MIExecReturn code never seems to be invoked by the MI CDI implementation.  Instead MIExecFinish is used.

The diference between the finish command and the return command is that the finish command continues execution unil the return from teh current stack frame whereas the return command just returns from the current stack frame.

Ewa.
Comment 4 Doug Schaefer CLA 2007-08-28 14:24:20 EDT
I was afraid of that...

At any rate, patch applied. Thanks!