Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 2 Oct 2014 06:29:49 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r272398 - head/usr.bin/sort
Message-ID:  <201410020629.s926TnT1078870@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Thu Oct  2 06:29:49 2014
New Revision: 272398
URL: https://svnweb.freebsd.org/changeset/base/272398

Log:
  Make sure to not skip any argument when converting from deprecated
  +POS1, -POS2 to -kPOS1,POS2, so that sort +0n gets translated to sort -k1,1n
  as it is expected
  
  PR:		193994
  Submitted by:	rodrigo
  MFC after:	3 days

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

Modified: head/usr.bin/sort/sort.c
==============================================================================
--- head/usr.bin/sort/sort.c	Thu Oct  2 06:00:55 2014	(r272397)
+++ head/usr.bin/sort/sort.c	Thu Oct  2 06:29:49 2014	(r272398)
@@ -897,7 +897,7 @@ fix_obsolete_keys(int *argc, char **argv
 						}
 					}
 				}
-				sprintf(sopt, "-k%d.%d", f1, c1);
+				sprintf(sopt, "-k%d.%d%s", f1, c1, sopts1);
 				argv[i] = sort_strdup(sopt);
 			}
 		}



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