Skip to content

Commit 96d2be9

Browse files
committed
fix build with usbtmc
1 parent 88e6da7 commit 96d2be9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/class/usbtmc/usbtmc_device.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -157,12 +157,12 @@ static bool handle_devMsgOut(uint8_t rhport, void *data, size_t len, size_t pack
157157
static uint8_t termChar;
158158
static uint8_t termCharRequested = false;
159159

160-
osal_mutex_def_t usbtmcLockBuffer;
160+
OSAL_MUTEX_DEF(usbtmcLockBuffer);
161161
static osal_mutex_t usbtmcLock;
162162

163163
// Our own private lock, mostly for the state variable.
164-
#define criticalEnter() do {osal_mutex_lock(usbtmcLock,OSAL_TIMEOUT_WAIT_FOREVER); } while (0)
165-
#define criticalLeave() do {osal_mutex_unlock(usbtmcLock); } while (0)
164+
#define criticalEnter() do { (void) osal_mutex_lock(usbtmcLock,OSAL_TIMEOUT_WAIT_FOREVER); } while (0)
165+
#define criticalLeave() do { (void) osal_mutex_unlock(usbtmcLock); } while (0)
166166

167167
bool atomicChangeState(usbtmcd_state_enum expectedState, usbtmcd_state_enum newState)
168168
{

0 commit comments

Comments
 (0)