[haiku-bugs] Re: [Haiku] #7039: [Network stack] Panic: _mutex_lock (): double lock

  • From: "jackburton" <trac@xxxxxxxxxxxx>
  • Date: Sat, 06 Sep 2014 19:22:58 -0000

#7039: [Network stack] Panic: _mutex_lock (): double lock
----------------------------------------+----------------------------
   Reporter:  diver                     |      Owner:  axeld
       Type:  bug                       |     Status:  new
   Priority:  normal                    |  Milestone:  R1
  Component:  Network & Internet/Stack  |    Version:  R1/Development
 Resolution:                            |   Keywords:
 Blocked By:                            |   Blocking:
Has a Patch:  1                         |   Platform:  All
----------------------------------------+----------------------------

Comment (by jackburton):

 The problem is that notify_device_monitor acquires the monitor lock (a
 mutex), then indirectly calls unregister_device_monitor, which acquires
 the lock again.
 I changed the mutex_to a recursive_lock, and the problem goes away.
 Please someone review the patch.

--
Ticket URL: <https://dev.haiku-os.org/ticket/7039#comment:6>
Haiku <https://dev.haiku-os.org>
Haiku - the operating system.

Other related posts: