Print this page
OS-1571 Placate gcc -Wparentheses
Reviewed by: Robert Mustacchi <rm@joyent.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/hyprlofs/hyprlofs_vnops.c
          +++ new/usr/src/uts/common/fs/hyprlofs/hyprlofs_vnops.c
↓ open down ↓ 546 lines elided ↑ open up ↑
 547  547  {
 548  548          int error;
 549  549          char *p, *pnm;
 550  550          vnode_t *realvp, *dvp;
 551  551          vattr_t va;
 552  552  
 553  553          /*
 554  554           * Get vnode for the real file/dir. We'll have a hold on realvp which
 555  555           * we won't vn_rele until hyprlofs_inactive.
 556  556           */
 557      -        if (error = lookupname(fspath, UIO_SYSSPACE, FOLLOW, NULLVPP, &realvp))
      557 +        if ((error = lookupname(fspath, UIO_SYSSPACE, FOLLOW, NULLVPP,
      558 +            &realvp)) != 0)
 558  559                  return (error);
 559  560  
 560  561          /* no devices allowed */
 561  562          if (IS_DEVVP(realvp)) {
 562  563                  VN_RELE(realvp);
 563  564                  return (ENODEV);
 564  565          }
 565  566  
 566  567          /*
 567  568           * realvp may be an AUTOFS node, in which case we perform a VOP_ACCESS
↓ open down ↓ 6 lines elided ↑ open up ↑
 574  575                  return (error);
 575  576          }
 576  577  
 577  578          /*
 578  579           * We're interested in the top most filesystem. This is specially
 579  580           * important when fspath is a trigger AUTOFS node, since we're really
 580  581           * interested in mounting the filesystem AUTOFS mounted as result of
 581  582           * the VOP_ACCESS() call not the AUTOFS node itself.
 582  583           */
 583  584          if (vn_mountedvfs(realvp) != NULL) {
 584      -                if (error = traverse(&realvp)) {
      585 +                if ((error = traverse(&realvp)) != 0) {
 585  586                          VN_RELE(realvp);
 586  587                          return (error);
 587  588                  }
 588  589          }
 589  590  
 590  591          va.va_type = VNON;
 591  592          /*
 592  593           * If the target name is a path, make sure we have all of the
 593  594           * intermediate directories, creating them if necessary.
 594  595           */
↓ open down ↓ 817 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX