First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 177114
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Jim Ramsay <lack@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Justin Bronder <jsbronder@gentoo.org>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
fluxbox.urxvt gdb log text/plain Justin Bronder 2007-05-05 03:26 0000 2.19 KB Details
ret_code.patch Check return codes from Xutf8TextPropertyToTextList text/plain Justin Bronder 2007-05-05 22:23 0000 885 bytes Details
ret_code.imp.patch Better patch patch Justin Bronder 2007-05-05 22:32 0000 663 bytes Details | Diff
fluxbox-1.0_rc3_p1.ebuild Ebuild using Mark's patch patch Justin Bronder 2007-05-05 23:12 0000 5.14 KB Details | Diff
fluxbox-fix-badlocale-crash.patch Mark's Patch patch Justin Bronder 2007-05-05 23:13 0000 1.62 KB Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 177114 depends on: Show dependency tree
Bug 177114 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2007-05-05 03:21 0000
Fluxbox will load correctly, but attempts to run a number of applications will
cause a core dump.  So far, I've verified that urxvt, firefox, and pidgin all
cause this.  However, xterm does not.

Reproducible: Always

Steps to Reproduce:
1. Copy /usr/share/fluxbox/ to test users .fluxbox
2. Start Fluxbox
3. From the menubar or "fluxbox run" or keys file, launch urxvt, firefox or
pidgin.

Actual Results:  
Core Dump

Expected Results:  
I get to browse the web and open lots of urxvt sessions.

I do have two monitors, however I've disabled the second in xorg.conf and
verified that the core dump still occurs.  This is on an older system (serac)
with an AMD Athlon 3400+.  Stangely, my newer system, with an AMD X2 3600+,
this does not occur.  

Fluxbox-0.9.15.1-r2 has been stable since it hit portage.


Portage 2.1.2.2 (default-linux/amd64/2006.1/desktop, gcc-4.1.1, glibc-2.5-r0,
2.6.21-ck x86_64)
=================================================================
System uname: 2.6.21-ck x86_64 AMD Athlon(tm) 64 Processor 3400+
Gentoo Base System release 1.12.9
Timestamp of tree: Sat, 05 May 2007 01:30:10 +0000
distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632)
[disabled]
ccache version 2.4 [enabled]
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r7
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=athlon64 -O2 -pipe -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config
/usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/php/apache1-php5/ext-active/
/etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/
/etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo
/etc/texmf/web2c"
CXXFLAGS="-march=athlon64 -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="ccache distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="rsync://distro.ibiblio.org/pub/linux/distributions/gentoo/
ftp://gentoo.chem.wisc.edu/gentoo/ ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo
http://mirror.datapipe.net/gentoo http://open-systems.ufl.edu/mirrors/gentoo
http://gentoo.binarycompass.org/ http://mirrors.acm.cs.rpi.edu/gentoo/
rsync://mirror.mcs.anl.gov/pub/gentoo/"
LANG="en_US.utf8"
LC_ALL="en_US.utf8"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
--force --whole-file --delete --delete-after --stats --timeout=180
--exclude=/distfiles --exclude=/local --exclude=/packages
--filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp/portage"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage
/usr/portage/local/layman/webapps-experimental"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="2 X acpi4linux alsa amd64 berkdb bitmap-fonts cairo cdparanoia cdr cli
cracklib crypt cups dbus dri dvd dvd4linux dvdr dvdread emboss encode ethereal
ex fam firefox flac fortran gif gpm gstreamer gtk2 hal iconv imlib ipv6 isdnlog
jpeg libg++ mad matroska matrox midi mikmod mp3 mpeg ncurses nls nptl nptlonly
nvidia ogg opengl pam pcre perl png ppds pppd python qt3 qt4 quicktime readline
reflection sdl session spell spl ssl tcpd truetype truetype-fonts type1-fonts
unicode vim-with-x vorbis xml xorg xv xvid zlib" ALSA_CARDS="emu10k1"
ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file
hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route
share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev"
KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001
mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="nv nvidia vesa"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS, LINGUAS, MAKEOPTS,
PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

------- Comment #1 From Justin Bronder 2007-05-05 03:25:08 0000 -------
As recommended on the fluxbox site, I built from source, using CFLAGS="-Wall
-g3" CXXFLAGS="-Wall -g3".  To be sure, I also applied the single patch
specified in the ebuild and configured with "./configure
--prefix=/usr/local/fluxbox-test --enable-nls --enable-imlib2
--sysconfdir=/etc/X11/fluxbox-test"

I'll attach the gdb log from a crash due to using urxvt.  I have the core dump
as well, but I'm not sure if I'm supposed to upload that?

------- Comment #2 From Justin Bronder 2007-05-05 03:26:15 0000 -------
Created an attachment (id=118193) [edit]
gdb log

Gdb log when causing a crash by launching urxvt.

------- Comment #3 From Jim Ramsay 2007-05-05 19:49:41 0000 -------
Very odd.  I'm using firefox and urxvt every day in fluxbox with no issues
whatsoever (though I'm on the x86 architecture, not amd64).

Your GDB backtrace is a bit confusing.  Could you please detail what exactly
you did to create this backtrace?  Also, please tell me exactly what source
tarball you used to compile the debug version - A lot of the line numbers
listed in the backtrace don't seem to match up with anything from the official
gentoo fluxbox-1.0_rc3.tar.gz

Could you please also try:

1) Reinstall fluxbox-1.0_rc3, and ensure you are not running some sort of other
version in your PATH instead of the '/usr/bin/fluxbox' one.

2) Remove your .fluxbox directory entirely, to rule out an error in
/usr/share/fluxbox/.  The first run should create ~/.fluxbox/ for you with the
same defaults.

If the crash still persists, please make a debug build based on the
fluxbox-1.0_rc3.tar.gz in /usr/portage/distfiles, and please capture not only
the gdb output, but your input as well.

------- Comment #4 From Justin Bronder 2007-05-05 20:03:34 0000 -------
(In reply to comment #3)
> Very odd.  I'm using firefox and urxvt every day in fluxbox with no issues
> whatsoever (though I'm on the x86 architecture, not amd64).
> 
> Your GDB backtrace is a bit confusing.  Could you please detail what exactly
> you did to create this backtrace?  Also, please tell me exactly what source
> tarball you used to compile the debug version - A lot of the line numbers
> listed in the backtrace don't seem to match up with anything from the official
> gentoo fluxbox-1.0_rc3.tar.gz
> 
> Could you please also try:
> 
> 1) Reinstall fluxbox-1.0_rc3, and ensure you are not running some sort of other
> version in your PATH instead of the '/usr/bin/fluxbox' one.
> 
> 2) Remove your .fluxbox directory entirely, to rule out an error in
> /usr/share/fluxbox/.  The first run should create ~/.fluxbox/ for you with the
> same defaults.
> 
> If the crash still persists, please make a debug build based on the
> fluxbox-1.0_rc3.tar.gz in /usr/portage/distfiles, and please capture not only
> the gdb output, but your input as well.
> 

1 and 2 were the first steps I took before reporting this.  I actually created
a new user, just to be sure that nothing in my current setup was causing the
crash.

I also found the gdb output confusing.  What happens is I set my .xinitrc to
lanunch an xterm, then start gdb from there.  The problem is, when I force the
crash, the xterm is no longer responsive.  What I did instead was modify my
.xinitrc to read:
exec xterm -geometry 200x70 -e ~/test_fluxbox

Where test_fluxbox is:
#!/bin/bash
gdb /usr/local/fluxbox-test/bin/fluxbox -ex 'set logging on' -ex r -ex detach
-ex quit

If there is a better way to capture the output, I'll gladly work with that.

I got the source from the Fluxbox website, but I'm rebuilding right now with
the  files from portage.  Will report when that is done.

------- Comment #5 From Justin Bronder 2007-05-05 21:10:26 0000 -------
Alright, I was able to get the exact output by sshing in from another machine
and starting urxvt from there.  Here is exactly what I did.

# Create the user.
useradd -d /home/flux -G tty,audio,cdrom,video,cdrw,users -m -s /bin/bash flux
su flux
. /etc/profile

# As flux, compile the debug build.
cp /usr/portage/distfiles/fluxbox-1.0rc3.tar.bz2 .
tar -xjf fluxbox-1.0rc3.tar.bz2
cd fluxbox-1.0rc3
export CFLAGS="-g3 -Wall"
export CXXFLAGS="-g3 -Wall"
./configure --enable-nls --sysconfdir=/etc/X11/fluxbox | tee
gentoo.configure.log
make | tee gentoo.make.log

# As root, install.
make install

# As flux, startx
echo "#!/bin/bash" > .xinitrc
echo "exec xterm -g 200x70" >> .xinitrc
startx -- :1

# Inside X, start gdb.
gdb /usr/local/bin/fluxbox
set logging on
set args -log fluxbox.log
r

# From another machine, ssh in and start urxvt.
ssh flux@serac
DISPLAY=:1.0 urxvt

# Here is the gdb output, I checked and it does match the source.
Starting program: /usr/local/bin/fluxbox

Program received signal SIGSEGV, Segmentation fault.
0x00000000004f897b in FbTk::FbWindow::textProperty (this=0x7c3a80,
property=297) at FbWindow.cc:492
492             ret = stringlist[0];
#0  0x00000000004f897b in FbTk::FbWindow::textProperty (this=0x7c3a80,
property=297) at FbWindow.cc:492
#1  0x00000000004bf76a in Ewmh::setupClient (this=0x7438a0,
winclient=@0x7c3a80) at Ewmh.cc:224
#2  0x000000000042036d in Fluxbox::attachSignals (this=0x6dad50,
winclient=@0x7c3a80) at fluxbox.cc:1279
#3  0x0000000000444388 in BScreen::createWindow (this=0x6e7a40, client=8388614)
at Screen.cc:1458
#4  0x00000000004229bb in Fluxbox::handleEvent (this=0x6dad50,
e=0x7fffbf16bba0) at fluxbox.cc:810
#5  0x000000000042302a in Fluxbox::eventLoop (this=0x6dad50) at fluxbox.cc:560
#6  0x000000000043d884 in main (argc=1, argv=0x7fffbf16c2a8) at main.cc:291
The program is running.  Exit anyway? (y or n)


#The fluxbox log
------------------------------------------
Log File: fluxbox.log
Fluxbox version: 1.0rc2
SVN Revision: 4737
Compiled: Mar  4 2007 11:04:25
Compiler: GCC
Compiler version: 4.1.1 (Gentoo 4.1.1)

Defaults:
    menu: /usr/local/fluxbox-test/share/fluxbox/menu
   style: /usr/local/fluxbox-test/share/fluxbox/styles/Clean
    keys: /usr/local/fluxbox-test/share/fluxbox/keys
    init: /usr/local/fluxbox-test/share/fluxbox/init
    nls: /usr/local/fluxbox-test/share/fluxbox/nls

Compiled options (- => disabled):
DEBUG
EWMH
-GNOME
IMLIB2
-KDE
NLS
REMEMBER
RENDER
SHAPE
SLIT
TOOLBAR
XFT
-XINERAMA
XMB
XPM

------------------------------------------
Failed to read: session.ignoreBorder
Setting default value
Failed to read: session.forcePseudoTransparency
...
Followed by a bunch of complaints the same as above.
...
Failed to read: session.screen1.iconbar.usePixmap
Setting default value
SystemTray.cc(SystemTray(const FbTk::FbWindow)): SETTING OWNER!
Failed to read: session.screen1.strftimeFormat
Setting default value
------------------
Setting Focused window = 0
Current Focused window = 0
------------------
PropertyNotify(test_fluxbox), property = _NET_WM_DESKTOP
PropertyNotify(test_fluxbox), property = _NET_FRAME_EXTENTS
PropertyNotify(test_fluxbox), property = WM_STATE
PropertyNotify(test_fluxbox), property = _BLACKBOX_ATTRIBUTES
PropertyNotify(test_fluxbox), property = _NET_WM_ALLOWED_ACTIONS
------------------
Setting Focused window = 0x705580
title: test_fluxbox
Current Focused window = 0
------------------
FluxboxWindow::setCurrentClient: labelbutton[client] = 0x7152d0
FluxboxWindow(test_fluxbox)::setFocusFlag(1)
------------------
Setting Focused window = 0
Current Focused window = 0x705580
------------------
FluxboxWindow(test_fluxbox)::setFocusFlag(0)
PropertyNotify(test_fluxbox), property = _NET_FRAME_EXTENTS
FluxboxWindow::setCurrentClient: labelbutton[client] = 0x7152d0
FluxboxWindow::setInputFocus isModal() = 0
FluxboxWindow::setInputFocus transient size = 0
------------------
Setting Focused window = 0x705580
title: test_fluxbox
Current Focused window = 0
------------------
FluxboxWindow::setCurrentClient: labelbutton[client] = 0x7152d0
FluxboxWindow(test_fluxbox)::setFocusFlag(1)
FluxboxWindow(test_fluxbox)::raise()[layer=8]
FluxboxWindow(test_fluxbox)::raise()[layer=8]
FluxboxWindow::buttonPressEvent: AllowEvent
MapRequest for 0x800006

------- Comment #6 From Jim Ramsay 2007-05-05 21:42:36 0000 -------
(In reply to comment #5)
> #The fluxbox log
> ------------------------------------------
> Log File: fluxbox.log
> Fluxbox version: 1.0rc2

I find this kind of odd - rc2?  What is the output of 'fluxbox -version'?  I
get:

  $ fluxbox -version
  Fluxbox 1.0rc3-gentoo : (c) 2001-2006 Henrik Kinnunen 

The rest I will mention to upstream, although the first comment I got when I
mentioned this issue is "It's fixed in rc3".

Thanks for the very detailed reoport!

------- Comment #7 From Justin Bronder 2007-05-05 21:54:15 0000 -------
(In reply to comment #6)
> (In reply to comment #5)
> > #The fluxbox log
> > ------------------------------------------
> > Log File: fluxbox.log
> > Fluxbox version: 1.0rc2
> 

Whoops!  Wrong log file.  Here is the correct output, I guess I should be
looking a little closer before I middle click.  Notice this one was actually
compiled today as well, better then March.

------------------------------------------
Log File: fluxbox.log
Fluxbox version: 1.0rc3
Compiled: May  5 2007 16:11:44
Compiler: GCC
Compiler version: 4.1.1 (Gentoo 4.1.1)

Defaults:
    menu: /usr/local/share/fluxbox/menu
   style: /usr/local/share/fluxbox/styles/Clean
    keys: /usr/local/share/fluxbox/keys
    init: /usr/local/share/fluxbox/init
    nls: /usr/local/share/fluxbox/nls

Compiled options (- => disabled):
-DEBUG
EWMH
GNOME
-IMLIB2
KDE
NLS
REMEMBER
RENDER
SHAPE
SLIT
TOOLBAR
XFT
-XINERAMA
XMB
XPM

------------------------------------------
Failed to read: session.ignoreBorder
Setting default value
Failed to read: session.forcePseudoTransparency

...

Failed to read: session.screen1.iconbar.usePixmap
Setting default value
Failed to read: session.screen1.strftimeFormat
Setting default value


Sorry for the bad log previously.

------- Comment #8 From Justin Bronder 2007-05-05 22:21:12 0000 -------
Well, I have a patch that gets rid of the core dump, but I doubt it's optimal. 
All I did was add some checking of return codes after the call to
Xutf8TextPropertyToTextList.  

The function is returning XLocaleNotSupported.  So I guess I need to look into
why that is happening.

------- Comment #9 From Justin Bronder 2007-05-05 22:23:04 0000 -------
Created an attachment (id=118297) [edit]
Check return codes from Xutf8TextPropertyToTextList

Not a good patch, but it at least stops the core dumping.

------- Comment #10 From Justin Bronder 2007-05-05 22:32:12 0000 -------
Created an attachment (id=118300) [edit]
Better patch

I just modeled this closer to what the rest of the
FbTk::FbWindow::textProperty() is doing when errors are returned.  This is a
lot better.

------- Comment #11 From Mark Tiefenbruck 2007-05-05 22:34:12 0000 -------
I came to the same conclusion based on your backtrace, though I went about it
slightly differently. Try checking out the latest stable svn version (svn co
svn://svn.berlios.de/fluxbox/trunk fluxbox && cd fluxbox && ./autogen.sh ...)
to see if I've fixed it.

------- Comment #12 From Justin Bronder 2007-05-05 22:48:13 0000 -------
Yup, works here.  I'm going to assume I can close this bug.

Thanks all.

------- Comment #13 From Justin Bronder 2007-05-05 23:12:28 0000 -------
Created an attachment (id=118303) [edit]
Ebuild using Mark's patch

For what it's worth, here's the patch and ebuild.

------- Comment #14 From Justin Bronder 2007-05-05 23:13:21 0000 -------
Created an attachment (id=118304) [edit]
Mark's Patch

Patch generated from the subversion checkout.

------- Comment #15 From Jim Ramsay 2007-05-07 15:21:35 0000 -------
Patch included in version 1.0_rc3-r1, in the tree now.

Thanks for the bug report, and a BIG thanks to Mark for the quick fix!

First Last Prev Next    No search results available      Search page      Enter new bug