URL: https://github.com/SSSD/sssd/pull/94
Title: #94: Enable {socket,dbus}-activation for responders

lslebodn commented:
"""
On (15/01/17 14:54), fidencio wrote:
>fidencio commented on this pull request.
>
>
>
>> +    }
>+
>+    /* As the service is a responder and wasn't part of the services' list, 
>it means
>+     * the service has been socket/dbus activated and has to be configured 
>and added
>+     * to the services' list now */
>+
>+    *_explicitly_configured = false;
>+    *_svc = NULL;
>+
>+    if (check_service(svc_name) != NULL) {
>+        DEBUG(SSSDBG_FATAL_FAILURE, "Invalid service %s\n", svc_name);
>+        return EINVAL;
>+    }
>+
>+    mini->ctx->services_started = true;
>+    mini->ctx->num_services++;
>
>Yep, we must decrease the num_services. Nice catch.
>

It might explain why I saw a crash. I will need to test with new version.

```
#0  monitor_service_shutdown (conn=0x7f80357cb880, data=<optimized out>) at 
src/monitor/monitor.c:2457
2457            if (svc->conn == conn) {

Thread 1 (Thread 0x7f8035380880 (LWP 24632)):
#0  monitor_service_shutdown (conn=0x7f80357cb880, data=<optimized out>) at 
src/monitor/monitor.c:2457
        ctx = 0x7f80357a5b30
        svc = 0xbebebebebebebebe
        __FUNCTION__ = "monitor_service_shutdown"
#1  0x00007f8030b65447 in _talloc_free_internal (ptr=0x7f80357cb880, 
location=0x7f8030b68a12 "../talloc.c:2631") at ../talloc.c:1046
        d = 0x7f80348dfe80 <sbus_connection_destructor>
        ptr_to_free = <optimized out>
#2  0x00007f8030b6501b in _talloc_free_children_internal 
(location=0x7f8030b68a12 "../talloc.c:2631", ptr=0x7f80357b5370, 
tc=0x7f80357b5310) at ../talloc.c:1525
        child = 0x7f80357cb880
        new_parent = 0x0
#3  _talloc_free_internal (ptr=0x7f80357b5370, location=0x7f8030b68a12 
"../talloc.c:2631") at ../talloc.c:1072
        ptr_to_free = <optimized out>
#4  0x00007f8030b6501b in _talloc_free_children_internal 
(location=0x7f8030b68a12 "../talloc.c:2631", ptr=0x7f80357a5b30, 
tc=0x7f80357a5ad0) at ../talloc.c:1525
        child = 0x7f80357b5370
        new_parent = 0x0
#5  _talloc_free_internal (ptr=0x7f80357a5b30, location=0x7f8030b68a12 
"../talloc.c:2631") at ../talloc.c:1072
        ptr_to_free = <optimized out>
#6  0x00007f8030b6501b in _talloc_free_children_internal 
(location=0x7f8030b68a12 "../talloc.c:2631", ptr=0x7f80357aca80, 
tc=0x7f80357aca20) at ../talloc.c:1525
        child = 0x7f80357a5b30
        new_parent = 0x0
#7  _talloc_free_internal (ptr=0x7f80357aca80, location=0x7f8030b68a12 
"../talloc.c:2631") at ../talloc.c:1072
        ptr_to_free = <optimized out>
#8  0x00007f8030b6501b in _talloc_free_children_internal 
(location=0x7f8030b68a12 "../talloc.c:2631", ptr=0x7f80357bcf10, 
tc=0x7f80357bceb0) at ../talloc.c:1525
        child = 0x7f80357aca80
        new_parent = 0x0
#9  _talloc_free_internal (ptr=0x7f80357bcf10, location=0x7f8030b68a12 
"../talloc.c:2631") at ../talloc.c:1072
        ptr_to_free = <optimized out>
#10 0x00007f8030b5eb63 in _talloc_free_children_internal 
(location=0x7f8030b68a12 "../talloc.c:2631", ptr=0x7f80357a6f50, 
tc=0x7f80357a6ef0) at ../talloc.c:1525
        child = 0x7f80357bcf10
        new_parent = 0x0
#11 _talloc_free_internal (location=<optimized out>, ptr=<optimized out>) at 
../talloc.c:1072
        ptr_to_free = <optimized out>
#12 _talloc_free (ptr=0x7f80357a6f50, location=0x7f8030b68a12 
"../talloc.c:2631") at ../talloc.c:1647
No locals.
#13 0x00007f80303caa49 in __run_exit_handlers (status=status@entry=1, 
listp=0x7f803074c6c8 <__exit_funcs>, 
run_list_atexit=run_list_atexit@entry=true) at exit.c:77
        atfct = <optimized out>
        onfct = <optimized out>
        cxafct = <optimized out>
        f = <optimized out>
#14 0x00007f80303caa95 in __GI_exit (status=status@entry=1) at exit.c:99
No locals.
#15 0x00007f80353d9917 in monitor_quit (ret=ret@entry=1, mt_ctx=0x7f80357a5b30) 
at src/monitor/monitor.c:1530
        svc = <optimized out>
        pid = <optimized out>
        status = 0
        error = <optimized out>
        kret = <optimized out>
        killed = <optimized out>
#16 0x00007f80353d9dea in monitor_restart_service (svc=0x7f80357ccbf0) at 
src/monitor/monitor.c:2639
        mt_ctx = 0x7f80357a5b30
        now = <optimized out>
        te = <optimized out>
#17 mt_svc_exit_handler (pid=<optimized out>, wait_status=<optimized out>, 
pvt=<optimized out>) at src/monitor/monitor.c:2602
        svc = 0x7f80357ccbf0
        __FUNCTION__ = "mt_svc_exit_handler"
#18 0x00007f80327acb77 in sss_child_invoke_cb (ev=<optimized out>, 
imm=0x7f80357ca6d0, pvt=<optimized out>) at src/util/child_common.c:181
        cb_pvt = 0x7f80357ce220
        child_ctx = 0x7f80357c6ab0
        key = {type = HASH_KEY_ULONG, {str = 0x6076 <Address 0x6076 out of 
bounds>, ul = 24694}}
        error = 0
        __FUNCTION__ = "sss_child_invoke_cb"
#19 0x00007f8030d70c34 in tevent_common_loop_immediate 
(ev=ev@entry=0x7f80357bcf10) at ../tevent_immediate.c:135
        im = 0x7f80357ca6d0
        handler = 0x7f80327acb00 <sss_child_invoke_cb>
        private_data = 0x7f80357ce220
#20 0x00007f8030d72384 in poll_event_loop_once (ev=0x7f80357bcf10, 
location=<optimized out>) at ../tevent_poll.c:649
No locals.
#21 0x00007f8030d7040d in _tevent_loop_once (ev=ev@entry=0x7f80357bcf10, 
location=location@entry=0x7f8034909327 "src/util/server.c:707") at 
../tevent.c:533
        ret = <optimized out>
        nesting_stack_ptr = 0x0
#22 0x00007f8030d71ebb in poll_event_loop_wait (ev=0x7f80357bcf10, 
location=0x7f8034909327 "src/util/server.c:707") at ../tevent_poll.c:677
        ret = <optimized out>
        poll_ev = 0x7f80357ad210
#23 0x00007f80348eb5d3 in server_loop (main_ctx=0x7f80357aca80) at 
src/util/server.c:707
No locals.
#24 0x00007f80353d717a in main (argc=<optimized out>, argv=<optimized out>) at 
src/monitor/monitor.c:2914
        opt = <optimized out>
        pc = <optimized out>
        opt_daemon = 0
        opt_interactive = 1
        opt_genconf = 0
        opt_version = 0
        opt_netlinkoff = 0
        opt_config_file = 0x0
        config_file = <optimized out>
        flags = <optimized out>
        main_ctx = 0x7f80357aca80
        tmp_ctx = 0x7f80357a59b0
        monitor = 0x7f80357a5b30
        ret = <optimized out>
        long_options = {{longName = 0x0, shortName = 0 '\000', argInfo = 4, arg 
= 0x7f8034696320 <poptHelpOptions>, val = 0, descrip = 0x7f80353e0b9a "Help 
options:", argDescrip = 0x0}, {longName = 0x7f80353e0ba8 "debug-level", 
shortName = 100 'd', argInfo = 2, arg = 0x7f803117f128 <debug_level>, val = 0, 
descrip = 0x7f80353e0bb4 "Debug level", argDescrip = 0x0}, {longName = 
0x7f80353e015f "debug-to-files", shortName = 102 'f', argInfo = 0, arg = 
0x7f803117f124 <debug_to_file>, val = 0, descrip = 0x7f80353e1ca8 "Send the 
debug output to files instead of stderr", argDescrip = 0x0}, {longName = 
0x7f80353e018c "debug-to-stderr", shortName = 0 '\000', argInfo = 1073741824, 
arg = 0x7f803117f120 <debug_to_stderr>, val = 0, descrip = 0x7f80353e1ce0 "Send 
the debug output to stderr directly.", argDescrip = 0x0}, {longName = 
0x7f80353e0bc0 "debug-timestamps", shortName = 0 '\000', argInfo = 2, arg = 
0x7f803117f0fc <debug_timestamps>, val = 0, descrip = 0x7f80353e0bd1 "Add debug 
timestamps", argDescrip = 0x0}, {longName = 0x7f80353e0be6 
"debug-microseconds", shortName = 0 '\000', argInfo = 2, arg = 0x7f803117f0f8 
<debug_microseconds>, val = 0, descrip = 0x7f80353e1d10 "Show timestamps with 
microseconds", argDescrip = 0x0}, {longName = 0x7f80353e0bf9 "daemon", 
shortName = 68 'D', argInfo = 0, arg = 0x7fffb030becc, val = 0, descrip = 
0x7f80353e0c00 "Become a daemon (default)", argDescrip = 0x0}, {longName = 
0x7f80353e0c1a "interactive", shortName = 105 'i', argInfo = 0, arg = 
0x7fffb030bed0, val = 0, descrip = 0x7f80353e1d38 "Run interactive (not a 
daemon)", argDescrip = 0x0}, {longName = 0x7f80353e0c26 "disable-netlink", 
shortName = 0 '\000', argInfo = 1073741824, arg = 0x7fffb030bedc, val = 0, 
descrip = 0x7f80353e0c36 "Disable netlink interface", argDescrip = 0x0}, 
{longName = 0x7f80353e3a2d "config", shortName = 99 'c', argInfo = 1, arg = 
0x7fffb030bee8, val = 0, descrip = 0x7f80353e1d58 "Specify a non-default config 
file", argDescrip = 0x0}, {longName = 0x7f80353e0c50 "genconf", shortName = 103 
'g', argInfo = 0, arg = 0x7fffb030bed4, val = 0, descrip = 0x7f80353e1d80 
"Refresh the configuration database, then exit", argDescrip = 0x0}, {longName = 
0x7f80353e3a1f "version", shortName = 0 '\000', argInfo = 0, arg = 
0x7fffb030bed8, val = 0, descrip = 0x7f80353e0c58 "Print version number and 
exit", argDescrip = 0x0}, {longName = 0x0, shortName = 0 '\000', argInfo = 0, 
arg = 0x0, val = 0, descrip = 0x0, argDescrip = 0x0}}
        __FUNCTION__ = "main"
```

"""

See the full comment at 
https://github.com/SSSD/sssd/pull/94#issuecomment-272829452
_______________________________________________
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org

Reply via email to