Bug 187083

Summary: [patch] sort(1) cannot be used for binary data.
Product: Base System Reporter: Shayan Pooya <shayan>
Component: binAssignee: freebsd-bugs (Nobody) <bugs>
Status: Open ---    
Severity: Affects Only Me Keywords: patch
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description Shayan Pooya 2014-02-26 14:40:01 UTC
Sort has an unnecessary check that prevents it from being used for binary data:
https://github.com/freebsd/freebsd/blob/master/usr.bin/sort/sort.c#L1063


Here is the mailing list discussion (not very useful):
http://freebsd.1045724.n5.nabble.com/Field-delimiter-in-sort-program-in-freebsd-td5879776.html

Fix: Just remove the bogus condition:

How-To-Repeat: $ sort -t $'\xff'

complains about the delimiter.
Comment 1 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:00:18 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped
Comment 2 Graham Perrin freebsd_committer freebsd_triage 2022-10-17 12:38:22 UTC
Keyword: 

    patch
or  patch-ready

– in lieu of summary line prefix: 

    [patch]

* bulk change for the keyword
* summary lines may be edited manually (not in bulk). 

Keyword descriptions and search interface: 

    <https://bugs.freebsd.org/bugzilla/describekeywords.cgi>