Bug #20098 Query browser is searching for a file that is not present (preferences.glade)
Submitted: 26 May 2006 20:26 Modified: 30 Jun 2006 20:08
Reporter: Georgi Sotirov Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Query Browser Severity:S1 (Critical)
Version:1.1.18 OS:Linux (Slackware Linux Current)
Assigned to: CPU Architecture:Any

[26 May 2006 20:26] Georgi Sotirov
Description:
I'm trying to build MySQL Query Browser from source on a Slackware Linux Current box. While the source builded and installed sucessfuly (without even warnings) the application crashes on start. It prints only this:

$ ./mysql-query-browser-bin 
*** glibc detected *** double free or corruption (out): 0x08263f18 ***
Aborted

When I ran it thourgh strace I've get the result posted in the steps to reproduce.

How to repeat:
$ tar -zxvf mysql-query-browser-1.1.18.tar.gz
$ cd mysql-gui-common
$ ./configure --prefix=/usr --build=i486-pc-linux-gnu
$ make
$ make DESTDIR=/tmp/mysql-qb install
$ cd ../mysql-query-browser
$ ./configure --prefix=/usr --build=i486-pc-linux-gnu --with-gtkhtml=libgtkhtml-3.8
$ make
$ make DESTDIR=/tmp/mysql-qb install
$cd /tmp/mysql-qb/usr/bin
$ export MQB_DIR=/tmp/mysql-qb/usr
$ strace mysql-query-browser-bin
...
stat64("/tmp/mysql-qb/usr/share/mysql-gui/query-browser/preferences.glade", 0xbffa6aa0) = -1 ENOENT (No such file or directory)
brk(0x871f000)                          = 0x871f000
brk(0x8717000)                          = 0x8717000
write(2, "\n(mysql-query-browser:7229): lib"..., 170
(mysql-query-browser:7229): libglade-WARNING **: could not find glade file '/tmp/mysql-qb/usr/share/mysql-gui/query-browser/preferences.glade'
) = 170
futex(0xb70dfc54, FUTEX_WAKE, 2147483647) = 0
futex(0xb702d584, FUTEX_WAKE, 2147483647) = 0
rt_sigprocmask(SIG_UNBLOCK, [ABRT], NULL, 8) = 0
tgkill(7229, 7229, SIGABRT)             = 0
--- SIGABRT (Aborted) @ 0 (0) ---
+++ killed by SIGABRT +++
Process 7229 detached

Suggested fix:
This file should be either present or not refered.
[26 May 2006 20:43] Georgi Sotirov
This also aplies to MySQL Administrator 1.1.10. Exactly the same case.
[29 May 2006 14:18] Alfredo Kojima
Hi

You must start QB (and MA) with the mysql-query-browser (or mysql-administrator) script, because they set environment variables with the paths to their datafiles, relative to the binary location.
[30 May 2006 15:10] Georgi Sotirov
There is no difference if the program is started with the script or directly if you export the required environment variables, which I've done (if you look closely in my code you will se this line $ export MQB_DIR=/tmp/mysql-qb/usr just before the trace). So the problem is not in the way the program is run. I've provided this trace with the intention to be more helpful, because the program won't start even if it is ran with the wrapper script. But there is no much information in this, isn't it?
[31 May 2006 19:51] Jorge del Conde
Hi!

While I was able to reproduce this, Alfredo's comments indicate that this is not a bug.  What's the reason you encounter by launching the apps with the appropiate scripts ?
[31 May 2006 20:01] Georgi Sotirov
OK. Here it is, but I don't know what information this gives:

$ ./mysql-query-browser
*** glibc detected *** double free or corruption (out): 0x08263f18 ***
./mysql-query-browser: line 20: 28814 Aborted                 $PRG-bin

$ ./mysql-administrator
*** glibc detected *** free(): invalid pointer: 0x081fe0e0 ***
./mysql-administrator: line 18: 28958 Aborted                 $PRG-bin $*
[31 May 2006 20:08] Jorge del Conde
Thanks, we'll check this out and see if we can find the cause for it.
[1 Jul 2006 23:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".