Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 17 Jan 2009 11:57:32 +0000 (UTC)
From:      Poul-Henning Kamp <phk@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r187360 - head/sbin/recoverdisk
Message-ID:  <200901171157.n0HBvW4K042178@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: phk
Date: Sat Jan 17 11:57:32 2009
New Revision: 187360
URL: http://svn.freebsd.org/changeset/base/187360

Log:
  Bail on ENXIO, you won't get any further any way.
  
  Submitted by:	tobez

Modified:
  head/sbin/recoverdisk/recoverdisk.c

Modified: head/sbin/recoverdisk/recoverdisk.c
==============================================================================
--- head/sbin/recoverdisk/recoverdisk.c	Sat Jan 17 11:19:15 2009	(r187359)
+++ head/sbin/recoverdisk/recoverdisk.c	Sat Jan 17 11:57:32 2009	(r187360)
@@ -276,7 +276,10 @@ main(int argc, char * const argv[])
 				lp->len -= i;
 				continue;
 			}
-			printf("\n%jd %zu failed %d\n", lp->start, i, errno);
+			printf("\n%jd %zu failed (%s)\n",
+			    lp->start, i, strerror(errno));
+			if (errno == ENXIO)
+				aborting = 1;
 			new_lump(lp->start, i, lp->state + 1);
 			lp->start += i;
 			lp->len -= i;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901171157.n0HBvW4K042178>