Print this page
OS-1840 fmdump shall emit JSON
Reviewed by: Robert Mustacchi <rm@joyent.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/fm/fmdump/common/error.c
          +++ new/usr/src/cmd/fm/fmdump/common/error.c
↓ open down ↓ 12 lines elided ↑ open up ↑
  13   13   * When distributing Covered Code, include this CDDL HEADER in each
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
       23 + * Copyright (c) 2013, Joyent, Inc. All rights reserved.
  23   24   */
  24   25  
  25   26  #include <fmdump.h>
  26   27  #include <stdio.h>
  27   28  #include <time.h>
  28   29  
  29   30  /*ARGSUSED*/
  30   31  static int
  31   32  err_short(fmd_log_t *lp, const fmd_log_record_t *rp, FILE *fp)
  32   33  {
↓ open down ↓ 71 lines elided ↑ open up ↑
 104  105  "TIME                 CLASS                                 ENA",
 105  106  (fmd_log_rec_f *)err_verb1
 106  107  }, {
 107  108  "TIME                           CLASS",
 108  109  (fmd_log_rec_f *)err_verb2
 109  110  }, {
 110  111  "TIME                           CLASS",
 111  112  (fmd_log_rec_f *)err_pretty
 112  113  }, {
 113  114  NULL, NULL
      115 +}, {
      116 +NULL,
      117 +(fmd_log_rec_f *)fmdump_print_json
 114  118  } }
 115  119  };
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX