Print this page
3910 t_look(3NSL) should never return T_ERROR

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/nfs/nfs_dump.c
          +++ new/usr/src/uts/common/fs/nfs/nfs_dump.c
↓ open down ↓ 11 lines elided ↑ open up ↑
  12   12   *
  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 + * Copyright 2014 Gary Mills
  22   23   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23   24   * Use is subject to license terms.
  24   25   */
  25   26  
  26   27  /*
  27   28   * Dump memory to NFS swap file after a panic.
  28   29   * We have no timeouts, context switches, etc.
  29   30   */
  30   31  
  31   32  #include <rpc/types.h>
↓ open down ↓ 330 lines elided ↑ open up ↑
 362  363  
 363  364          *badmsg = 0;
 364  365  
 365  366          rudata.addr.maxlen = 0;
 366  367          rudata.opt.maxlen = 0;
 367  368          rudata.udata.udata_mp = (mblk_t *)NULL;
 368  369  
 369  370          nd_log("nfs_dump: calling t_krcvudata\n");
 370  371  
 371  372          if (error = t_krcvudata(tiptr, &rudata, &type, &uderr)) {
      373 +                if (error == EBADMSG) {
      374 +                        cmn_err(CE_WARN, "\tnfs_dump:  received EBADMSG");
      375 +                        *badmsg = 1;
      376 +                        return (0);
      377 +                }
 372  378                  nfs_perror(error, "\nnfs_dump: t_krcvudata failed: %m\n");
 373  379                  return (EIO);
 374  380          }
 375  381          if (type != T_DATA) {
 376  382                  cmn_err(CE_WARN, "\tnfs_dump:  received type %d", type);
 377  383                  *badmsg = 1;
 378  384                  return (0);
 379  385          }
 380  386          if (!rudata.udata.udata_mp) {
 381  387                  cmn_err(CE_WARN, "\tnfs_dump: null receive");
↓ open down ↓ 138 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX