From owner-svn-src-all@FreeBSD.ORG Sat Jun 22 03:44:49 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id ED6BDC23; Sat, 22 Jun 2013 03:44:49 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DFC3619A7; Sat, 22 Jun 2013 03:44:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r5M3in1V062546; Sat, 22 Jun 2013 03:44:49 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r5M3in5O062545; Sat, 22 Jun 2013 03:44:49 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201306220344.r5M3in5O062545@svn.freebsd.org> From: Devin Teske Date: Sat, 22 Jun 2013 03:44:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r252084 - head/usr.sbin/bsdconfig/share/media X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Jun 2013 03:44:50 -0000 Author: dteske Date: Sat Jun 22 03:44:49 2013 New Revision: 252084 URL: http://svnweb.freebsd.org/changeset/base/252084 Log: Trim the trailing `/' from the ftp_dir when validating that the directory exists on the FTP server. This now means that when you specify a full-path to the repository on the FTP server that it doesn't matter whether you have a trailing `/' or not. Modified: head/usr.sbin/bsdconfig/share/media/ftp.subr Modified: head/usr.sbin/bsdconfig/share/media/ftp.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/media/ftp.subr Sat Jun 22 02:57:52 2013 (r252083) +++ head/usr.sbin/bsdconfig/share/media/ftp.subr Sat Jun 22 03:44:49 2013 (r252084) @@ -659,7 +659,10 @@ f_media_init_ftp() break # to failure fi if echo "$rx" | awk -v dir="/${ftp_dir#/}" ' - BEGIN { found = 0 } + BEGIN { + found = 0 + sub("/$", "", dir) + } /^Remote directory: / { sub(/^[^:]*:[[:space:]]*/, "") if ($0 != dir) next