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 152891 - The Step Into action doesn't work right after first debuger finishing
Summary: The Step Into action doesn't work right after first debuger finishing
Status: VERIFIED FIXED
Alias: None
Product: debugger
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-10 17:10 UTC by Martin Fousek
Modified: 2009-02-19 20:38 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Fousek 2008-11-10 17:10:52 UTC
Product Version: NetBeans IDE 6.5 (Build 200811100001)
Java: 1.6.0_10-rc; Java HotSpot(TM) Client VM 11.0-b13
System: Linux version 2.6.24-19-generic running on i386; UTF-8; en_US (nb)

Observed:
Create some Web Application with some servlet. In the servlet place breakpoint on some line with calling any function.
After then invoke debugging and wait till the debugger hit the breakpoint, invoke "step into" - debugger should stop on
the first line of the function. Finish the debugger and try it again. Now, when you invoke "Step into", it doesn't work
right.
Comment 1 Martin Entlicher 2008-11-11 22:10:41 UTC
Reproduced. It does not stop on the second Step Into and continues to the next breakpoint.
Step Into Next Method (SHIFT-F7) works right.
Comment 2 Martin Entlicher 2008-11-12 08:38:22 UTC
It should be fixed by changeset:   107886:6c7a37876a09
http://hg.netbeans.org/main/rev/6c7a37876a09
Comment 3 Quality Engineering 2008-11-12 16:46:05 UTC
Integrated into 'main-golden', will be available in build *200811121401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/6c7a37876a09
User: mentlicher@netbeans.org
Log: #152891 - It neems to be necessary to set the count filter for the breakpoint to actually work.
Comment 4 rbalada 2008-11-14 10:12:12 UTC
Please verify this issue so it can be included in NetBeans 6.5 Patch1
Comment 5 Filip Zamboj 2008-11-14 13:53:33 UTC
Seems to be working fine. Checked as verified. 
Comment 6 rbalada 2008-11-18 13:47:31 UTC
I've transplanted the changeset http://hg.netbeans.org/main/rev/6c7a37876a09 into release65_fixes repository as
http://hg.netbeans.org/release65_fixes/rev/b6c721921985
Comment 7 Martin Fousek 2008-11-24 11:57:37 UTC
I try it in NetBeans IDE Dev (Build 200811240201) and the fix doesn't work for me. 

Please try the "Step Into" action in the servlet. I have something like this in servlet ...

protected void processRequest(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, IOException {
        response.setContentType("text/html;charset=UTF-8");
        PrintWriter out = response.getWriter();
        try {            
            out.println("<html>");
            out.println("<head>");
            out.println("<title>Servlet adder</title>");  
            out.println("</head>");
            out.println("<body>");
            out.println("<h1>Adder servlet</h1>");
            printResult(request, response, out);
            out.println("</body>");
            out.println("</html>");
        } finally { 
            out.close();
        }
    }

private void printResult(HttpServletRequest req, HttpServletResponse res, PrintWriter out) {
        float num1 = Float.parseFloat(req.getParameter("num1"));
        float num2 = Float.parseFloat(req.getParameter("num2"));
        out.print( num1 + " + " + num2 + " = ");
        out.println(num1+num2);
    }

Copy (or overwrite) part of this code into your servlet and place the breakpoint on the line "printResult(request,
response, out);". After then invoke debugging and try Step Into action.
Comment 8 Martin Entlicher 2008-11-24 13:20:37 UTC
Reproduced. This seems to be a different issue, since the Step Into action does not work since the first attempt. Going
to explore what's wrong...
Comment 9 Martin Entlicher 2008-11-24 14:24:54 UTC
This is a very strange behavior. I'm able to reproduce the problem in build 200811240201 from bits.netbeans.org. But as
soon as I start NetBeans in debug mode, Step Into behaves correctly! I'm not able to reproduce this at all in my own
build compiled from NetBeans sources.
From these symptoms this looks like some subtle race-condition...
Comment 10 Martin Entlicher 2008-11-24 14:46:29 UTC
marfous, is this reproducible also in 6.5?
Comment 11 Martin Fousek 2008-11-24 15:02:22 UTC
Yes, I was testing it now and I'm able to reproduce it in 6.5. 

So, may I fill new issue and we close this one as fixed (because of different issue)?
Comment 12 Martin Entlicher 2008-11-24 15:18:16 UTC
Yes please, fill a new issue. This is already fixed, including 6.5 patch, so it's better to have a separate issue for a
different problem. Thanks.
Comment 13 Martin Fousek 2008-11-24 15:36:45 UTC
OK. So this issue is fixed, I will fill a new one. Verified.