Skip to content
  • Jan Kiszka's avatar
    cobalt/posix/mqueue: Fix crash after failing registration · 4924717e
    Jan Kiszka authored
    
    
    If xnregistry_enter in mq_open fails, the new entry will not be added to
    cobalt_mqq. But the cleanup path taken afterwards will nevertheless try
    to remove it from there. That will cause a crash because the mq->link is
    uninitialized. Fix that by initializing it as list head so that list
    removal becomes harmless, even when the entry is not on any list..
    
    Signed-off-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
    4924717e