2 Copyright © 1995-2013, The AROS Development Team. All rights reserved.
9 #include <proto/exec.h>
10 #include <dos/dosextens.h>
11 #include <proto/dos.h>
12 #include "dos_intern.h"
13 #include <aros/debug.h>
15 /*****************************************************************************
18 #include <proto/dos.h>
20 AROS_LH1(BOOL
, UnLock
,
23 AROS_LHA(BPTR
, lock
, D1
),
26 struct DosLibrary
*, DOSBase
, 15, Dos
)
30 Free a lock created with Lock().
33 lock - The lock to free
47 *****************************************************************************/
51 /* Get pointer to filehandle */
52 struct FileLock
*fl
= BADDR(lock
);
54 ASSERT_VALID_PTR_OR_NULL(fl
);
55 ASSERT_VALID_FILELOCK(lock
);
57 D(bug("UnLock(%x)\n", fl
));
59 /* 0 handles are OK */
63 return dopacket1(DOSBase
, NULL
, fl
->fl_Task
, ACTION_FREE_LOCK
, lock
) != 0;