Description of problem: cupsd can segfault while using the libdns_sd compatibility layer of Avahi. Version-Release number of selected component (if applicable): avahi-0.6.20-7.fc8 How reproducible: Fairly easy here. Steps to Reproduce: 1.service avahi-daemon stop; service cups stop 2.service avahi-daemon start; cupsd -f Actual results: Segfault. Additional info: #0 0x0012d402 in __kernel_vsyscall () #1 0x00440160 in raise () from /lib/libc.so.6 #2 0x00441aa1 in abort () from /lib/libc.so.6 #3 0x0043956e in __assert_fail () from /lib/libc.so.6 #4 0x00792422 in avahi_entry_group_add_service_strlst (group=0xb8421e20, interface=-1, protocol=-1, flags=0, name=0x0, type=0xb842d9b8 "_ipp._tcp", domain=0xb842d4f8 "local", host=0x0, port=631, txt=0xb842d938) at entrygroup.c:424 424 assert(name); #5 0x0024f895 in reg_create_service (sdref=0xb842d9d8) at compat.c:923 923 if ((ret = avahi_entry_group_add_service_strlst( #6 0x0024fcf5 in reg_client_callback (s=0xb842d018, state=AVAHI_CLIENT_S_RUNNING, userdata=0xb842d9d8) at compat.c:996 996 if ((ret = reg_create_service(sdref)) < 0) { #7 0x0078eccd in client_set_state (client=0xb842d018, state=AVAHI_SERVER_RUNNING) at client.c:101 101 client->callback (client, state, client->userdata); #8 0x007904c1 in filter_func (bus=0xb8421628, message=0xb841fb48, userdata=0xb842d018) at client.c:188 188 client_set_state(client, (AvahiClientState) state); #9 0x00215684 in dbus_connection_dispatch () from /lib/libdbus-1.so.3 #10 0x00797a9c in dispatch_timeout_callback (t=0xb842d5e0, userdata=0xb842d228) at ../avahi-common/dbus-watch-glue.c:103 103 if (dbus_connection_dispatch(d->connection) == DBUS_DISPATCH_DATA_REMAINS) #11 0x0078619a in timeout_callback (t=0x6) at simple-watch.c:449 449 t->callback(t, t->userdata); #12 0x00786451 in avahi_simple_poll_dispatch (s=0xb842ce88) at simple-watch.c:562 562 timeout_callback(next_timeout); #13 0x00251362 in DNSServiceProcessResult (sdref=0xb842d9d8) at compat.c:497 497 if (avahi_simple_poll_dispatch(sdref->simple_poll) < 0) #14 0xb7eeeb23 in cupsdUpdateDNSSDBrowse (p=0xb840bf48) at dirsvc.c:1364 1364 if ((sdErr = DNSServiceProcessResult(p->dnssd_ipp_ref)) Attached patch fixes it here.
Created attachment 161058 [details] avahi-dnssd-compat.patch
Aaarg, I forgot about this patch when I preprared Avahi 0.6.21. Hmm, patch doesn't look entirely right to me. I will look into this again later and cook up another patch for the Fedora package. For not forgetting about this again I posted this upstream, too: http://avahi.org/ticket/154
This is still causing cupsd to abort on boot-up. Please fix for test2.
Hmm, I wonder what I was thinking when I looked at your patch the first time. It's perfectly correct. I will merge this now into the avahi packages. Sorry for the delay!
OK, this is now fixed in rawhide. I am not sure though what is necessary to get this tagges for test2.