[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [MiNT] /proc



> -----Original Message-----
> From: Julian Reschke [mailto:reschke@muenster.de]
> Sent: Thursday, November 18, 1999 11:25 AM
> To: Jo-Even.Skarstein@gjensidige.no; mint@fishpool.com
> Subject: RE: [MiNT] /proc
> 
> It isn't solved under MagiC. And as SLBs do not show up in 
> u:\proc, there is
> nothing you could apply the ioctl() to...

Ahh... Well, I guess it's possible to expand Slbopen, perhaps by using
negative values in min_er. E.g...

SLB_FIRST -1
SLB_NEXT  -2

...in min_ver will return the pid of the process(es) in a longword pointed
to by *slb:

long client_pid, next;

next = Slbopen("foobar.slb", NULL, SLB_FIRST, &client_pid, slb_exec);
while (next)
{
   next = Slbopen("foobar.slb", NULL, SLB_NEXT, &client_pid, slb_exec);
}

Ugly, but I guess it will work. You could also introduce two new opcodes,
e.g...

long Slb_client_first(char *name, char *path, long *pid)
long Slb_client_next(long *pid)


Jo Even Skarstein