The branch, master has been updated
       via  1c76746 notifyd: prevent NULL deref segfault in 
notifyd_peer_destructor
      from  f85f4ce swrap: Update to version 1.1.7

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 1c76746b637bc1867f85ba94786b89f22d1b0c32
Author: Michael Adam <ob...@samba.org>
Date:   Fri May 20 12:57:48 2016 +0200

    notifyd: prevent NULL deref segfault in notifyd_peer_destructor
    
    It seems it could happen that p->db == NULL in the list
    from notifyd_clean_peers_next(). This has been seen in
    a ctdb cluster when an node-internal ctdb interface is
    brought down.
    
    BUG: https://bugzilla.samba.org/show_bug.cgi?id=11930
    
    Signed-off-by: Michael Adam <ob...@samba.org>
    Reviewed-by: Volker Lendecke <v...@samba.org>
    
    Autobuild-User(master): Volker Lendecke <v...@samba.org>
    Autobuild-Date(master): Fri May 20 17:32:55 CEST 2016 on sn-devel-144

-----------------------------------------------------------------------

Summary of changes:
 source3/smbd/notifyd/notifyd.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)


Changeset truncated at 500 lines:

diff --git a/source3/smbd/notifyd/notifyd.c b/source3/smbd/notifyd/notifyd.c
index 49fb9c9..45b029b 100644
--- a/source3/smbd/notifyd/notifyd.c
+++ b/source3/smbd/notifyd/notifyd.c
@@ -1246,7 +1246,10 @@ static int notifyd_peer_destructor(struct notifyd_peer 
*p)
        struct notifyd_state *state = p->state;
        size_t i;
 
-       dbwrap_traverse_read(p->db, notifyd_db_del_syswatches, NULL, NULL);
+       if (p->db != NULL) {
+               dbwrap_traverse_read(p->db, notifyd_db_del_syswatches,
+                                    NULL, NULL);
+       }
 
        for (i = 0; i<state->num_peers; i++) {
                if (p == state->peers[i]) {


-- 
Samba Shared Repository

Reply via email to