Bug 198899

Summary: jdns.c:list_delete() collides with list_delete() in libmysqlclient_r.so
Product: [Unmaintained] kopete Reporter: Daniel Eklöf <daniel>
Component: Jabber PluginAssignee: Kopete Developers <kopete-bugs-null>
Status: RESOLVED UPSTREAM    
Severity: crash CC: cfeck
Priority: NOR    
Version First Reported In: SVN   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Daniel Eklöf 2009-07-04 13:37:45 UTC
Version:           0.70.90 (using Devel)
Compiler:          gcc-4.4.0 
OS:                Linux
Installed from:    Compiled sources

When connecting to my Jabber account, kopete crashes:

Thread 1 (Thread 0x7fd23b93e760 (LWP 5536)):
[KCrash Handler]
#5  0x00007fd2310a26c0 in list_delete () from /usr/lib64/libmysqlclient_r.so.16
#6  0x00007fd222686c01 in jdns_session_delete () from /usr/lib64/kde4/kopete_jabber.so

The call to list_delete in mysql looked weired and I couldn't understand why kopete would do that. Turns out there is a local function in kopete/protocols/jabber/libiris/iris/jdns/jdns.c that it intended to call. Only problem is that list_delete in jdns.c isn't marked as static, making it choose list_delete from mysql instead!

This patch fixes the issue for me:

Index: protocols/jabber/libiris/iris/jdns/jdns.c
===================================================================
--- protocols/jabber/libiris/iris/jdns/jdns.c   (revision 991182)
+++ protocols/jabber/libiris/iris/jdns/jdns.c   (working copy)
@@ -486,7 +486,7 @@
        return l;
 }

-void list_delete(list_t *l)
+static void list_delete(list_t *l)
 {
        int n;
        if(!l)
Comment 1 Daniel Eklöf 2009-07-04 13:39:21 UTC
mysql version was 5.1.32. I'm now running 5.1.36 and it too has the list_delete() function.
Comment 2 Daniel Eklöf 2010-07-18 15:27:20 UTC
This has apparently been fixed upstream (https://delta.affinix.com/svn/trunk/iris/src/jdns/jdns.c@677)

So, looks like this bug can be closed as soon as kopete upgrades to the latest libiris.
Comment 3 Christoph Feck 2013-09-12 21:47:05 UTC
This crash report is at least 3 years old and there were no further comments or status updates since then.

Therefore we believe that this crash is already fixed in recent KDE 4 versions or the backtrace is no longer applicable to the current KDE 4 sources.

If the crash still happens with a recent KDE version (4.10.5 or 4.11), please add an updated backtrace or provide steps to reproduce. For more information, see http://techbase.kde.org/Development/Tutorials/Debugging/How_to_create_useful_crash_reports

(To prevent automatic closing of this bug in the future, please set the bug status to ASSIGNED or CONFIRMED)