We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6e3e03f commit ae730acCopy full SHA for ae730ac
fs/vfs/fs_lock.c
@@ -36,6 +36,7 @@
36
#include <nuttx/list.h>
37
38
#include "lock.h"
39
+#include "sched/sched.h"
40
41
/****************************************************************************
42
* Pre-processor Definitions
@@ -94,9 +95,12 @@ static mutex_t g_protect_lock = NXMUTEX_INITIALIZER;
94
95
96
static int file_lock_get_path(FAR struct file *filep, FAR char *path)
97
{
98
+ FAR struct tcb_s *tcb = this_task();
99
+
100
/* We only apply file lock on mount points (f_inode won't be NULL). */
101
- if (!INODE_IS_MOUNTPT(filep->f_inode))
102
+ if (!INODE_IS_MOUNTPT(filep->f_inode) ||
103
+ tcb->flags & TCB_FLAG_SIGNAL_ACTION)
104
105
return -EBADF;
106
}
0 commit comments