Print this page
12364 mdb trips assertion related to autowrap

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/mdb/common/mdb/mdb_set.c
          +++ new/usr/src/cmd/mdb/common/mdb/mdb_set.c
↓ open down ↓ 16 lines elided ↑ open up ↑
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
  23   23   * Use is subject to license terms.
  24   24   */
  25   25  
  26   26  /*
  27      - * Copyright 2017 Joyent, Inc.
       27 + * Copyright 2020 Joyent, Inc.
  28   28   */
  29   29  
  30   30  /*
  31   31   * Support for ::set dcmd.  The +/-o option processing code is provided in a
  32   32   * stand-alone function so it can be used by the command-line option processing
  33   33   * code in mdb_main.c.  This facility provides an easy way for us to add more
  34   34   * configurable options without having to add a new dcmd each time.
  35   35   */
  36   36  
  37   37  #include <mdb/mdb_target.h>
↓ open down ↓ 230 lines elided ↑ open up ↑
 268  268              mdb.m_prompt);
 269  269  
 270  270          mdb_printf("%*s ", LABEL_INDENT, "debugger options:");
 271  271          (void) mdb_inc_indent(LABEL_INDENT + 1);
 272  272  
 273  273          /*
 274  274           * The ::set output implicitly relies on "autowrap" being enabled, so
 275  275           * we enable it for the duration of the command.
 276  276           */
 277  277          oflags = mdb.m_flags;
 278      -        mdb.m_flags |= MDB_FL_AUTOWRAP;
      278 +        mdb_iob_set_autowrap(mdb.m_out);
 279  279  
 280  280          mdb_printf("follow_exec_mode=");
 281  281          switch (mdb.m_execmode) {
 282  282          case MDB_EM_ASK:
 283  283                  mdb_printf("ask");
 284  284                  break;
 285  285          case MDB_EM_STOP:
 286  286                  mdb_printf("stop");
 287  287                  break;
 288  288          case MDB_EM_FOLLOW:
↓ open down ↓ 177 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX