This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 181751

Summary: Simple Attach does not work
Product: cnd Reporter: Alexander Pepin <apepin>
Component: executionAssignee: Andrew Krasny <akrasny>
Status: RESOLVED FIXED    
Severity: normal Keywords: REGRESSION
Priority: P2    
Version: 6.x   
Hardware: PC   
OS: All   
Issue Type: DEFECT Exception Reporter:

Description Alexander Pepin 2010-03-10 05:18:10 UTC
Steps to reproduce:
- create Quote sample
- set 'Output Window' as 'Console Type'
- run the project
- press "Attach Debugger" button in the Output window
Result: "The requested process no longer exists" information window appears.
Comment 1 Egor Ushakov 2010-03-10 06:46:41 UTC
reproduced only with profiling turned off.
Comment 2 Andrew Krasny 2010-03-10 08:08:08 UTC
Confirmed.
Comment 3 Andrew Krasny 2010-03-10 08:22:53 UTC
Evaluation:

DefaultProjectActionHandler is an ExecutionListener. It remembers PID of the started process once it is launched. The problem is that it takes pid (of event) on the wrong stage (STARTING), which indicates that process is _about_ to start. It should do it on (RUNNING), which means that process was successfully started, event.
Comment 4 Andrew Krasny 2010-03-10 08:25:38 UTC
http://hg.netbeans.org/cnd-main/rev/0315b114ccb2