Author: vangyzen
Date: Mon Jan 13 22:36:29 2020
New Revision: 356709
URL: https://svnweb.freebsd.org/changeset/base/356709

Log:
  fstyp hammer2: remove dead code
  
  best_i will always be >= 0, so remove code to test otherwise.
  
  Reported by:  Coverity
  CID:          1412244
  MFC after:    2 weeks
  Sponsored by: Dell EMC Isilon
  Differential Revision:        https://reviews.freebsd.org/D23159

Modified:
  head/usr.sbin/fstyp/hammer2.c

Modified: head/usr.sbin/fstyp/hammer2.c
==============================================================================
--- head/usr.sbin/fstyp/hammer2.c       Mon Jan 13 22:33:48 2020        
(r356708)
+++ head/usr.sbin/fstyp/hammer2.c       Mon Jan 13 22:36:29 2020        
(r356709)
@@ -87,11 +87,6 @@ __read_label(FILE *fp, char *label, size_t size)
                        best = broot;
                }
        }
-       if (best_i == -1) {
-               warnx("Failed to find volume header from zones");
-               error = 1;
-               goto done;
-       }
 
        bref = &vols[best_i]->voldata.sroot_blockset.blockref[0];
        if (bref->type != HAMMER2_BREF_TYPE_INODE) {
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to