Oracle® Solaris Studio 12.4: dbxtool Tutorial

Exit Print View

Updated: October 2014
 
 

Step 10: Breakpoint Conditions

    To add a condition to your watchpoint:

  1. In the Breakpoints window, right-click the After Write breakpoint and choose Customize.

  2. Verify that After is selected in the When field.

    Selecting After enables you to see what the value of err_silent was changed to.

  3. Set the Condition field to err_silent == -1.

  4. Click OK.

    image:Customize Breakpoint dialog box
  5. Run the program again.

    You stop in checkThings(), which is the first time err_silent is set to -1. As you look for the matching err_silent++ you see what looks like a bug: err_silent is incremented only in the else portion of the function.

    image:Editor window showing program stopped in                                                 checkThings

    Could this be the bug you've been looking for?