[comp.sys.atari.st] 40 folders & regexp

dal@stag.UUCP (Dale Schumacher) (02/09/88)

  <apratt@atari.UUCP (Allan Pratt)> writes...
> The memory allocation for this pool is pretty bad.  Mainly, once a
> directory descriptor is allocated from it, it only gets freed when
> there's a media-change on that drive.
> 
> Hard drives never show media change, so directory descriptors are never
> freed.

Would it be possible to fake a media change for a hard drive?  If so, a
small TSR could be written that would sit on the V-blank or 200Hz timer
and cause media changes every once in a while.  I imagine a media change
on the hard disk wouldn't get in the way much, since it should be fairly
quick to reload.  Do you see any problems with this idea?

........

And now, on a different topic...
  <rogers@ncrcce.StPaul.NCR.COM> asks...
> Does dLibs or any other public domain library contain a version of "regexp"?

That's a good question.  I have a partial version of "regexp", but I'm still
putting the finishing touches on it.  The Un*x standard implementation of
this function set is really a kludge, but I assume that's how people will
want them implemented.  As far as I know, no other C library for the ST has
these functions at all.

                Dale Schumacher
                ..ihnp4!meccts!stag!syntel!dal
                (alias: Dalnefre')

exodus@uop.edu (G.Onufer) (02/12/88)

>   <rogers@ncrcce.StPaul.NCR.COM> asks...
> > Does dLibs or any other public domain library contain a version of "regexp"?


Try the regexp package that comes with gnu...  I have not really had a chance
to try it, but it is in my libutil.a file!!  It compiles just fine under
MWC 2.xx ...  the trickiest part is trying to get 'ar' to make ranlib...
but once known, 'tis never forgotten.  It is in .../gnuemacs/src/regexp.{c,h}

G. Onufer

apratt@atari.UUCP (Allan Pratt) (02/17/88)

in article <332@stag.UUCP>, syntel!dal@stag.UUCP (Dale Schumacher) says:
> Would it be possible to fake a media change for a hard drive?  If so, a
> small TSR could be written that would sit on the V-blank or 200Hz timer
> and cause media changes every once in a while.  I imagine a media change
> on the hard disk wouldn't get in the way much, since it should be fairly
> quick to reload.  Do you see any problems with this idea?

Yes: a huge one.  When you get media change on a drive, all open files
on that drive are closed & forgotten.  No data is flushed, no warnings
are issued... You just get kicked out in the street.  Not a fun thing
to have happen at Vblank time.

Having a program which causes media change is another matter.  In fact
I have one, and use it when I pop a floppy, modify that floppy on another
machine, and re-insert it in the original.  (Without such a program,
the state would go from not-changed to (pop disk) maybe-changed to
(re-insert, check serial number) not-changed.

But it requires user intervention, and the better solution is just
to fix the damn bug in the first place.

============================================
Opinions expressed above do not necessarily	-- Allan Pratt, Atari Corp.
reflect those of Atari Corp. or anyone else.	  ...ames!atari!apratt