IsAstack ( )

Chipp Walters chipp at chipp.com
Fri Jul 13 00:29:18 CDT 2007


I'm all for checking to see if a stack exists. Here's why.

Many times a stack can be downloaded incompletely by a user for a
variety of reasons. If you just check the filename, or the first 8
bytes, you may not know the stack is corrupted or incomplete.

So, what to do if there already is a stack with the same name open?
Just curious, would this work?

lock messages
if there is a stack tStackPath then
  put true into tExists
  delete stack tStackPath
else
  put false into tExists
end if
unlock messages

I would think this would work even with namespace collisions, as the
delete stack explicitly names the stacks filepath.

-Chipp


More information about the metacard mailing list