Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 9/18/84; site brl-tgr.ARPA
Path: utzoo!watmath!clyde!cbosgd!ihnp4!houxm!mhuxr!ulysses!allegra!mit-eddie!godot!harvard!seismo!brl-tgr!gwyn
From: gwyn@brl-tgr.ARPA (Doug Gwyn )
Newsgroups: net.lang.c
Subject: Re: pipes and the sort command
Message-ID: <6770@brl-tgr.ARPA>
Date: Thu, 27-Dec-84 00:10:03 EST
Article-I.D.: brl-tgr.6770
Posted: Thu Dec 27 00:10:03 1984
Date-Received: Thu, 27-Dec-84 03:37:46 EST
References: <1650@drutx.UUCP>
Organization: Ballistic Research Lab
Lines: 9

> 	I am interested in using the popen() command to form a pipe
> 	between my C program and the UNIX sort command. I would appreciate
> 	any information on the best way to do this(examples would help).
> 	I should point out that the input to the sort command would be
> 	comming from an array and the output should be stored in an array.

It is very hard to manage both ends of a piped filter from a program.

Have you considered using the qsort() library routine to sort your data?