Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
View | Details | Raw Unified | Return to bug 170488 | Differences between
and this patch

Collapse All | Expand All

(-)cnd.debugger.gdb2/src/org/netbeans/modules/cnd/debugger/gdb2/Gdb.java (+13 lines)
 Lines 486-491    Link Here 
486
		    return;
486
		    return;
487
		}
487
		}
488
		tentativeGdb.setExecutor(executor);
488
		tentativeGdb.setExecutor(executor);
489
		tentativeGdb.setPid(pid);
489
	    }
490
	    }
490
491
491
            tentativeGdb.myMIProxy.logInfo();
492
            tentativeGdb.myMIProxy.logInfo();
 Lines 688-694    Link Here 
688
     * Interrupt the program (note that unlike almost every other debugging
689
     * Interrupt the program (note that unlike almost every other debugging
689
     * action, we're NOT asking dbx to do it - this we're actually doing
690
     * action, we're NOT asking dbx to do it - this we're actually doing
690
     * ourselves!!
691
     * ourselves!!
692
     * 
693
     * On embedded targets SIGINT must be sent to GDB, not the target process
691
     */
694
     */
695
    private int gdbpid;
696
    
697
    void setPid(int pid) {
698
        gdbpid = pid;
699
    }
700
701
    int getPid() {
702
        return gdbpid;
703
    }    
704
    
692
    boolean pause(int pid, boolean silentStop, boolean interruptGdb) {
705
    boolean pause(int pid, boolean silentStop, boolean interruptGdb) {
693
        // The following predicate is _not_ the same as isReceptive()
706
        // The following predicate is _not_ the same as isReceptive()
694
        if (debugger.state().isRunning && debugger.state().isProcess) {
707
        if (debugger.state().isRunning && debugger.state().isProcess) {
(-)cnd.debugger.gdb2/src/org/netbeans/modules/cnd/debugger/gdb2/GdbDebuggerImpl.java (-2 / +4 lines)
 Lines 765-771    Link Here 
765
        String remoteTarget = gdi.getTargetCommand();
765
        String remoteTarget = gdi.getTargetCommand();
766
        if (remoteTarget != null) {
766
        if (remoteTarget != null) {
767
            cmdString = "target " + remoteTarget;  //NOI18N
767
            cmdString = "target " + remoteTarget;  //NOI18N
768
            targetAttach = true;
768
            // Leave this as false because to interrupt a gdbserver session
769
            // you must send a SIGINT to the host side gdb session
770
            //targetAttach = true;
769
        } else {
771
        } else {
770
            pid = gdi.getPid();
772
            pid = gdi.getPid();
771
            // MI command "-target-attach pid | file" does not available in
773
            // MI command "-target-attach pid | file" does not available in
 Lines 792-798    Link Here 
792
        state().isProcess = true;
794
        state().isProcess = true;
793
        stateChanged();
795
        stateChanged();
794
        session().setSessionState(state());
796
        session().setSessionState(state());
795
        long pid = getNDI().getPid();
797
        long pid = gdb.getPid();
796
        if (pid != -1) {
798
        if (pid != -1) {
797
            session().setPid(pid);
799
            session().setPid(pid);
798
        }
800
        }

Return to bug 170488
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo