From owner-svn-src-stable-8@FreeBSD.ORG Sat Jul 2 18:43:36 2011 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1AAF31065670; Sat, 2 Jul 2011 18:43:36 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 09E228FC08; Sat, 2 Jul 2011 18:43:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id p62IhZqk051491; Sat, 2 Jul 2011 18:43:35 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id p62IhZOq051489; Sat, 2 Jul 2011 18:43:35 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201107021843.p62IhZOq051489@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Sat, 2 Jul 2011 18:43:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r223725 - stable/8/sbin/geom/class/part X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Jul 2011 18:43:36 -0000 Author: ae Date: Sat Jul 2 18:43:35 2011 New Revision: 223725 URL: http://svn.freebsd.org/changeset/base/223725 Log: Since head/ and stable/8 have different handling for geom control request parameters, r215941 should be modified to allow use -F option in the "gpart restore" command - "force" parameter should be ascii string. This is direct commit to stable/8. Reported by: Maxim Ignatenko Modified: stable/8/sbin/geom/class/part/geom_part.c Modified: stable/8/sbin/geom/class/part/geom_part.c ============================================================================== --- stable/8/sbin/geom/class/part/geom_part.c Sat Jul 2 16:20:58 2011 (r223724) +++ stable/8/sbin/geom/class/part/geom_part.c Sat Jul 2 18:43:35 2011 (r223725) @@ -828,8 +828,8 @@ gpart_restore(struct gctl_req *req, unsi classp->lg_name); gctl_ro_param(r, "verb", -1, "destroy"); gctl_ro_param(r, "flags", -1, "restore"); - gctl_ro_param(r, "force", sizeof(forced), - &forced); + gctl_ro_param(r, "force", -1, + forced ? "1": "0"); gctl_ro_param(r, "geom", -1, s); errstr = gctl_issue(r); if (errstr != NULL && errstr[0] != '\0') {