Welcome, Guest. Please login or register.

Author Topic: Getting *locked* in  (Read 2085 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline Thomas

Re: Getting *locked* in
« on: April 22, 2004, 03:17:31 PM »
Why don't you read what people tell you : http://www.amiga.org/forums/showthread.php?t=8046

You must not UnLock() any locks you didn't Lock() on your own. And you must not UnLock() any lock currently in use by DOS.

The only allowed sequence is:

lock1 = Lock(dir1)
oldlock = CurrentDir(lock1)
lock2 = Lock(dir2)
CurrentDir(lock2)   /* should return lock1 */
UnLock (lock1)
lock3 = Lock(dir3)
CurrentDir(lock3)   /* should return lock2 */
UnLock (lock2)
Currentdir (oldlock) /* should return lock3 */
UnLock (lock3)

Bye,
Thomas