Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 May 2012 13:08:30 +0000 (UTC)
From:      Gabor Kovesdan <gabor@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r235546 - head/usr.bin/sort
Message-ID:  <201205171308.q4HD8U3o099994@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gabor
Date: Thu May 17 13:08:30 2012
New Revision: 235546
URL: http://svn.freebsd.org/changeset/base/235546

Log:
  - Fix -o option that was broken by my clang compile fix
  
  Submitted by:	Oleg Moskalenko <oleg.moskalenko@citrix.com>

Modified:
  head/usr.bin/sort/sort.c

Modified: head/usr.bin/sort/sort.c
==============================================================================
--- head/usr.bin/sort/sort.c	Thu May 17 11:53:38 2012	(r235545)
+++ head/usr.bin/sort/sort.c	Thu May 17 13:08:30 2012	(r235546)
@@ -1049,9 +1049,8 @@ main(int argc, char **argv)
 				sort_opts_vals.mflag = true;
 				break;
 			case 'o':
-				outfile = sort_realloc(outfile, sizeof(char) *
-				    (strlen(optarg) + 1));
-				strlcpy(outfile, optarg, strlen(outfile));
+				outfile = sort_realloc(outfile, (strlen(optarg) + 1));
+				strcpy(outfile, optarg);
 				break;
 			case 's':
 				sort_opts_vals.sflag = true;



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