--On Sunday, November 02, 2008 10:50:00 PM -0600 Nicolas Williams 
<Nicolas.Williams at sun.com> wrote:

> On Mon, Nov 03, 2008 at 03:06:58AM +0100, Roland Mainz wrote:
>> What about the following API:
>
> I hinted at this when I suggested, tongue-in-cheek, that NUL would be a
> better argument separator than \377.

And when you did, I pointed out that this approach would make it impossible 
to represent an empty argument, as two successive NUL characters would 
indicate the end of the stream.

Also, I really don't think this makes the interface "simple"; it makes it 
obscure and baroque and increases the likelyhood that the implementation 
will be buggy.

> I think a varargs approach would be easier to use.

I think most of us agree on this point.


> In fact, all we
> really need is a varages version of posix_spawn(), plus a varargs
> utility wrapper for the most common usage case.

Perhaps.  The proposed interface does have the advantage that, like 
system(3C), it blocks until the child process exits and automatically 
collects the exit status.

-- Jeff

Reply via email to