🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.next.programmer
Article #507

Re: signals and the appkit

#507
From: Chris Lloyd
Date: Sat, 08 Aug 1992 20:38
27 lines
1728 bytes
In article <1992Aug7.141211.25648@mcs.anl.gov> olson@mcs.anl.gov (Bob Olson) writes:
>In article <1992Aug6.230949.7527@nic.umass.edu>  
>a74k110@titan.ucc.umass.edu (Chris Lloyd) writes:
>> It would be handy to have a fork() variant which returned a task_t for
>> the child...
>
>It would seem you could create one using task_create() and  
>thread_create(), the latter necessary due to...
>
>> The function task_create() creates a new task from parent_task; the 
>> resulting task (child_task) acquires shared or copied parts of the 
>> parent's address space (see vm_inherit()).  The child task initially has
>> no threads; you put threads in it using thread_create().  

While this does work, the end result isn't a Unix process, it's a Mach
task:

root       -1 ?    0.0  S    10   0:00.00   0:00.00  <mach-task>

No file descriptors is a major bummer, you'd have to do all your IO thru
the parent or another process that does have access to the file system.
Not to mention exec's dont work, you'd have to load/link in the file
and start up the tthread by hand, yow, are we having fun yet? :)

la la la,
-- 
:: Christopher Lloyd :: a74k110@titan.ucc.umass.edu :: Yrrid, Inc. ::
Technical Details
Message-ID: <1992Aug8.203854.8745@nic.umass.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!caen!nic.umass.edu!titan.ucc.umass.edu!a74k110
References: <1992Aug6.230949.7527@nic.umass.edu> <1992Aug7.141211.25648@mcs.anl.gov>

Show Full Headers
Complete Article Headers
Newsgroups: comp.sys.next.programmer
Path: arc1-ca.pugleaf.net!sparky!uunet!caen!nic.umass.edu!titan.ucc.umass.edu!a74k110
From: a74k110@titan.ucc.umass.edu (Chris Lloyd)
Subject: Re: signals and the appkit
Message-ID: <1992Aug8.203854.8745@nic.umass.edu>
Sender: usenet@nic.umass.edu (USENET News System)
Nntp-Posting-Host: titan.ucc.umass.edu
Organization: University of Massachusetts, Amherst
References: <1992Aug6.230949.7527@nic.umass.edu> <1992Aug7.141211.25648@mcs.anl.gov>
Date: Sat, 8 Aug 1992 20:38:54 GMT
Lines: 27