Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 219343 - sys-apps/slocate-3.1-r1 aborts with "double free or corruption (fasttop)"
Summary: sys-apps/slocate-3.1-r1 aborts with "double free or corruption (fasttop)"
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on: 338380
Blocks:
  Show dependency tree
 
Reported: 2008-04-26 14:53 UTC by Kevin Parent
Modified: 2010-12-18 17:14 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
reproduce crash (crash.txt,4.02 KB, text/plain)
2009-01-14 09:32 UTC, Fab
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Parent 2008-04-26 14:53:07 UTC
"locate */.Xresouces" yields an abort using slocate-3.1-r1.  It appears to be similar if not the same as Bug #133053.

Reproducible: Always

Steps to Reproduce:
1. Update slocate to 3-1-r1 and run "updatedb"
2. Run the command "locate */.Xresources
3. Watch it fail

Actual Results:  
*** glibc detected *** slocate: double free or corruption (fasttop): 0x080538d0 ***
======= Backtrace: =========
/lib/libc.so.6[0xb7ea0a00]
/lib/libc.so.6(cfree+0x89)[0xb7ea26f9]
slocate[0x804afb9]
slocate[0x804adfc]
/lib/libc.so.6(__libc_start_main+0xdc)[0xb7e50fdc]
slocate[0x8049291]
======= Memory map: ========
08048000-08050000 r-xp 00000000 08:03 329902     /usr/bin/slocate
08050000-08051000 r--p 00007000 08:03 329902     /usr/bin/slocate
08051000-08052000 rw-p 00008000 08:03 329902     /usr/bin/slocate
08052000-08073000 rw-p 08052000 00:00 0          [heap]
b7cf5000-b7cfe000 r-xp 00000000 08:03 392497     /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7cfe000-b7cff000 r--p 00008000 08:03 392497     /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7cff000-b7d00000 rw-p 00009000 08:03 392497     /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7d00000-b7d21000 rw-p b7d00000 00:00 0
b7d21000-b7e00000 ---p b7d21000 00:00 0
b7e07000-b7e0f000 r-xp 00000000 08:03 397516     /lib/libnss_files-2.6.1.so
b7e0f000-b7e10000 r--p 00007000 08:03 397516     /lib/libnss_files-2.6.1.so
b7e10000-b7e11000 rw-p 00008000 08:03 397516     /lib/libnss_files-2.6.1.so
b7e11000-b7e19000 r-xp 00000000 08:03 399525     /lib/libnss_nis-2.6.1.so
b7e19000-b7e1a000 r--p 00007000 08:03 399525     /lib/libnss_nis-2.6.1.so
b7e1a000-b7e1b000 rw-p 00008000 08:03 399525     /lib/libnss_nis-2.6.1.so
b7e1b000-b7e2e000 r-xp 00000000 08:03 395957     /lib/libnsl-2.6.1.so
b7e2e000-b7e2f000 r--p 00012000 08:03 395957     /lib/libnsl-2.6.1.so
b7e2f000-b7e30000 rw-p 00013000 08:03 395957     /lib/libnsl-2.6.1.so
b7e30000-b7e32000 rw-p b7e30000 00:00 0
b7e32000-b7e38000 r-xp 00000000 08:03 399522     /lib/libnss_compat-2.6.1.so
b7e38000-b7e39000 r--p 00005000 08:03 399522     /lib/libnss_compat-2.6.1.so
b7e39000-b7e3a000 rw-p 00006000 08:03 399522     /lib/libnss_compat-2.6.1.so
b7e3a000-b7e3b000 rw-p b7e3a000 00:00 0
b7e3b000-b7f65000 r-xp 00000000 08:03 399531     /lib/libc-2.6.1.so
b7f65000-b7f67000 r--p 0012a000 08:03 399531     /lib/libc-2.6.1.so
b7f67000-b7f68000 rw-p 0012c000 08:03 399531     /lib/libc-2.6.1.so
b7f68000-b7f6c000 rw-p b7f68000 00:00 0
b7f82000-b7f83000 r-xp b7f82000 00:00 0          [vdso]
b7f83000-b7f9d000 r-xp 00000000 08:03 399523     /lib/ld-2.6.1.so
b7f9d000-b7f9e000 r--p 00019000 08:03 399523     /lib/ld-2.6.1.so
b7f9e000-b7f9f000 rw-p 0001a000 08:03 399523     /lib/ld-2.6.1.so
bf878000-bf88d000 rw-p bffeb000 00:00 0          [stack]
Aborted


Expected Results:  
Should run without crashing

Rolling back to slocate-2.7-r8 solves the issue

# emerge --info
Portage 2.1.4.4 (default-linux/x86/2007.0/desktop, gcc-4.1.2, glibc-2.6.1-r0, 2.6.24-gentoo-r4 i686)
=================================================================
System uname: 2.6.24-gentoo-r4 i686 Intel(R) Celeron(R) CPU 530 @ 1.73GHz
Timestamp of tree: Sat, 26 Apr 2008 13:45:01 +0000
app-shells/bash:     3.2_p17-r1
dev-java/java-config: 1.3.7, 2.1.4
dev-lang/python:     2.4.4-r9
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r1
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.23-r3
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=prescott -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=prescott -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="buildpkg distlocks metadata-transfer sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://mirror/espri.arizona.edu http://distfiles.gentoo.org http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LINGUAS="en_US en"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa arts berkdb cairo cddb cdparanoia cdr cli cpudetection cracklib crypt cups dbus dri dts dv dvd dvdread eds emboss encode esd evo fam ffmpeg firefox foomaticdb fortran gdbm gif gpm gstreamer hal iconv imagemagick isdnlog jpeg kde lame ldap libsamplerate mad midi mikmod mmx mmxext mp2 mp3 mpeg mudflap musicbrainz ncurses nls nptl nptlonly nsplugin ogg opengl openmp oss pam pcre pdf perl png pppd python qt3 qt3support qt4 quicktime readline real reflection sdl session sox spell spl sse sse2 ssl ssse3 svg tcpd tiff truetype type1 unicode vorbis win32codecs wmf x86 xine xml xorg xv xvid xvmc zlib" ALSA_CARDS="hda-intel" 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" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="evdev keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_US en" USERLAND="GNU" VIDEO_CARDS="i810"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Muelli 2008-05-25 18:12:13 UTC
I'm hitting the same problem.

rootbox ~ # gdb locate
GNU gdb 6.7.1
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...
Using host libthread_db library "/lib/libthread_db.so.1".
(gdb) break malloc_printerr
Function "malloc_printerr" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y

Breakpoint 1 (malloc_printerr) pending.
(gdb) run about*.desktop
Starting program: /usr/bin/locate about*.desktop
Breakpoint 2 at 0xb7e85946
Pending breakpoint "malloc_printerr" resolved
/opt/gnome2/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about-me.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/.svn/text-base/gnome-about.desktop.in.in.svn-base
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in.in

Breakpoint 2, 0xb7e85946 in malloc_printerr () from /lib/libc.so.6
(gdb) bt full
#0  0xb7e85946 in malloc_printerr () from /lib/libc.so.6
No symbol table info available.
#1  0xb7e876f9 in free () from /lib/libc.so.6
No symbol table info available.
#2  0x0804b218 in free_cmd_data (cmd_data=0xb7f4d120) at cmds.c:63
No locals.
#3  0x0804af6b in main (argc=134560328, argv=0x632f6169) at slocate.c:805
	g_data = (struct g_data_s *) 0x80538d0
	cmd_data = (struct cmd_data_s *) 0x4
	ret = 0
	search_ret = 134559976
#4  0xb7e35fdc in __libc_start_main () from /lib/libc.so.6
No symbol table info available.
#5  0x080493c1 in _start ()
No symbol table info available.
(gdb) cont
Continuing.
*** glibc detected *** /usr/bin/locate: double free or corruption (fasttop): 0x080538d0 ***
======= Backtrace: =========
/lib/libc.so.6[0xb7e85a00]
/lib/libc.so.6(cfree+0x89)[0xb7e876f9]
/usr/bin/locate[0x804b218]
======= Memory map: ========
08048000-08050000 r-xp 00000000 fe:00 8629447    /usr/bin/slocate
08050000-08051000 r--p 00007000 fe:00 8629447    /usr/bin/slocate
08051000-08052000 rw-p 00008000 fe:00 8629447    /usr/bin/slocate
08052000-08073000 rw-p 08052000 00:00 0          [heap]
b7c00000-b7c21000 rw-p b7c00000 00:00 0 
b7c21000-b7d00000 ---p b7c21000 00:00 0 
b7dec000-b7df4000 r-xp 00000000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7df4000-b7df5000 r--p 00007000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7df5000-b7df6000 rw-p 00008000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7df6000-b7dfe000 r-xp 00000000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7dfe000-b7dff000 r--p 00007000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7dff000-b7e00000 rw-p 00008000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e00000-b7e13000 r-xp 00000000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e13000-b7e14000 r--p 00012000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e14000-b7e15000 rw-p 00013000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e15000-b7e17000 rw-p b7e15000 00:00 0 
b7e17000-b7e1d000 r-xp 00000000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e1d000-b7e1e000 r--p 00005000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e1e000-b7e1f000 rw-p 00006000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e1f000-b7e20000 rw-p b7e1f000 00:00 0 
b7e20000-b7f4a000 r-xp 00000000 fe:00 7874349    /lib/libc-2.6.1.so
b7f4a000-b7f4c000 r--p 0012a000 fe:00 7874349    /lib/libc-2.6.1.so
b7f4c000-b7f4d000 rw-p 0012c000 fe:00 7874349    /lib/libc-2.6.1.so
b7f4d000-b7f51000 rw-p b7f4d000 00:00 0 
b7f69000-b7f73000 r-xp 00000000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f73000-b7f74000 r--p 00009000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f74000-b7f75000 rw-p 0000a000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f75000-b7f76000 rw-p b7f75000 00:00 0 
b7f76000-b7f90000 r-xp 00000000 fe:00 7875733    /lib/ld-2.6.1.so
b7f90000-b7f91000 r--p 00019000 fe:00 7875733    /lib/ld-2.6.1.so
b7f91000-b7f92000 rw-p 0001a000 fe:00 7875733    /lib/ld-2.6.1.so
bfa08000-bfa1d000 rw-p bffeb000 00:00 0          [stack]
ffffe000-fffff000 r-xp 00000000 00:00 0          [vdso]

Program received signal SIGABRT, Aborted.
0xffffe410 in __kernel_vsyscall ()
(gdb) 
Comment 2 SpanKY gentoo-dev 2008-08-19 00:49:33 UTC
delete the database manually, then run updatedb and see if you have the same prob

does that glob actually expand into anything ?

are you running the command as root ?
Comment 3 Muelli 2008-08-22 10:06:34 UTC
(In reply to comment #2)
> delete the database manually, then run updatedb and see if you have the same
> prob
> 
I can't access my desktop right now, where I hit this issue originally. I can't reproduce it on my server with slocate-3.1-r1 and a refreshed database (after a "updatedb"). I know, that my Desktop runs a different glibc, so I post version information for my server here as it might be important: sys-libs/glibc-2.6.1
> does that glob actually expand into anything ?
> 
No.
> are you running the command as root ?
> 
I was running the command as root.

I'll try in a few weeks, when I have access to my desktop. Feel free to remind me if I don't reply.
Comment 4 Kevin Parent 2008-09-14 16:51:44 UTC
Sorry for my tardiness.  I ran into this on a new system as well.  Seems like slocate doesn't like the '.'

I deleted the db /var/lib/slocate/slocate.db and ran updatedb as requested.  It still barfs.

> does that glob actually expand into anything ?

Not sure what you mean.  I posted the complete output.

are you running the command as root ?

Yes
Comment 5 Muelli 2008-09-14 19:31:55 UTC
I still run into this issue:

rootbox ~ # rm /var/lib/slocate/slocate.db 
rootbox ~ # updatedb
rootbox ~ # locate about*.desktop
/opt/gnome2/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about-me.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/.svn/text-base/gnome-about.desktop.in.in.svn-base
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in.in
*** glibc detected *** locate: double free or corruption (fasttop): 0x080538d0 ***
======= Backtrace: =========
/lib/libc.so.6[0xb7e89a00]
/lib/libc.so.6(cfree+0x89)[0xb7e8b6f9]
locate[0x804b218]
======= Memory map: ========
08048000-08050000 r-xp 00000000 fe:00 8629447    /usr/bin/slocate
08050000-08051000 r--p 00007000 fe:00 8629447    /usr/bin/slocate
08051000-08052000 rw-p 00008000 fe:00 8629447    /usr/bin/slocate
08052000-08073000 rw-p 08052000 00:00 0          [heap]
b7c00000-b7c21000 rw-p b7c00000 00:00 0 
b7c21000-b7d00000 ---p b7c21000 00:00 0 
b7df0000-b7df8000 r-xp 00000000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7df8000-b7df9000 r--p 00007000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7df9000-b7dfa000 rw-p 00008000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7dfa000-b7e02000 r-xp 00000000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e02000-b7e03000 r--p 00007000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e03000-b7e04000 rw-p 00008000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e04000-b7e17000 r-xp 00000000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e17000-b7e18000 r--p 00012000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e18000-b7e19000 rw-p 00013000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e19000-b7e1b000 rw-p b7e19000 00:00 0 
b7e1b000-b7e21000 r-xp 00000000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e21000-b7e22000 r--p 00005000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e22000-b7e23000 rw-p 00006000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e23000-b7e24000 rw-p b7e23000 00:00 0 
b7e24000-b7f4e000 r-xp 00000000 fe:00 7874349    /lib/libc-2.6.1.so
b7f4e000-b7f50000 r--p 0012a000 fe:00 7874349    /lib/libc-2.6.1.so
b7f50000-b7f51000 rw-p 0012c000 fe:00 7874349    /lib/libc-2.6.1.so
b7f51000-b7f55000 rw-p b7f51000 00:00 0 
b7f6e000-b7f78000 r-xp 00000000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f78000-b7f79000 r--p 00009000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f79000-b7f7a000 rw-p 0000a000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f7a000-b7f7b000 rw-p b7f7a000 00:00 0 
b7f7b000-b7f95000 r-xp 00000000 fe:00 7875733    /lib/ld-2.6.1.so
b7f95000-b7f96000 r--p 00019000 fe:00 7875733    /lib/ld-2.6.1.so
b7f96000-b7f97000 rw-p 0001a000 fe:00 7875733    /lib/ld-2.6.1.so
bf981000-bf996000 rw-p bffeb000 00:00 0          [stack]
ffffe000-fffff000 r-xp 00000000 00:00 0          [vdso]
Aborted
rootbox ~ # 

rootbox ~ # locate 'about*.desktop'
/opt/gnome2/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about-me.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/.svn/text-base/gnome-about.desktop.in.in.svn-base
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in.in
*** glibc detected *** locate: double free or corruption (fasttop): 0x080538d0 ***
======= Backtrace: =========
/lib/libc.so.6[0xb7edfa00]
/lib/libc.so.6(cfree+0x89)[0xb7ee16f9]
locate[0x804b218]
======= Memory map: ========
08048000-08050000 r-xp 00000000 fe:00 8629447    /usr/bin/slocate
08050000-08051000 r--p 00007000 fe:00 8629447    /usr/bin/slocate
08051000-08052000 rw-p 00008000 fe:00 8629447    /usr/bin/slocate
08052000-08073000 rw-p 08052000 00:00 0          [heap]
b7d00000-b7d21000 rw-p b7d00000 00:00 0 
b7d21000-b7e00000 ---p b7d21000 00:00 0 
b7e46000-b7e4e000 r-xp 00000000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7e4e000-b7e4f000 r--p 00007000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7e4f000-b7e50000 rw-p 00008000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7e50000-b7e58000 r-xp 00000000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e58000-b7e59000 r--p 00007000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e59000-b7e5a000 rw-p 00008000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7e5a000-b7e6d000 r-xp 00000000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e6d000-b7e6e000 r--p 00012000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e6e000-b7e6f000 rw-p 00013000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7e6f000-b7e71000 rw-p b7e6f000 00:00 0 
b7e71000-b7e77000 r-xp 00000000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e77000-b7e78000 r--p 00005000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e78000-b7e79000 rw-p 00006000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e79000-b7e7a000 rw-p b7e79000 00:00 0 
b7e7a000-b7fa4000 r-xp 00000000 fe:00 7874349    /lib/libc-2.6.1.so
b7fa4000-b7fa6000 r--p 0012a000 fe:00 7874349    /lib/libc-2.6.1.so
b7fa6000-b7fa7000 rw-p 0012c000 fe:00 7874349    /lib/libc-2.6.1.so
b7fa7000-b7fab000 rw-p b7fa7000 00:00 0 
b7fc4000-b7fce000 r-xp 00000000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7fce000-b7fcf000 r--p 00009000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7fcf000-b7fd0000 rw-p 0000a000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7fd0000-b7fd1000 rw-p b7fd0000 00:00 0 
b7fd1000-b7feb000 r-xp 00000000 fe:00 7875733    /lib/ld-2.6.1.so
b7feb000-b7fec000 r--p 00019000 fe:00 7875733    /lib/ld-2.6.1.so
b7fec000-b7fed000 rw-p 0001a000 fe:00 7875733    /lib/ld-2.6.1.so
bfed7000-bfeec000 rw-p bffeb000 00:00 0          [stack]
ffffe000-fffff000 r-xp 00000000 00:00 0          [vdso]
Aborted
rootbox ~ # echo about*.desktop
about*.desktop
rootbox ~ # su - muelli
Oh what a tangled web we weave, when first we practice to deceive.
		-- Shakespeare
muelli@rootbox ~ $  locate 'about*.desktop'
/opt/gnome2/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about-me.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/.svn/text-base/gnome-about.desktop.in.in.svn-base
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in.in
*** glibc detected *** locate: double free or corruption (fasttop): 0x080538d0 ***
======= Backtrace: =========
/lib/libc.so.6[0xb7e6ea00]
/lib/libc.so.6(cfree+0x89)[0xb7e706f9]
locate[0x804b218]
======= Memory map: ========
08048000-08050000 r-xp 00000000 fe:00 8629447    /usr/bin/slocate
08050000-08051000 r--p 00007000 fe:00 8629447    /usr/bin/slocate
08051000-08052000 rw-p 00008000 fe:00 8629447    /usr/bin/slocate
08052000-08073000 rw-p 08052000 00:00 0          [heap]
b7c00000-b7c21000 rw-p b7c00000 00:00 0 
b7c21000-b7d00000 ---p b7c21000 00:00 0 
b7dd5000-b7ddd000 r-xp 00000000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7ddd000-b7dde000 r--p 00007000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7dde000-b7ddf000 rw-p 00008000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7ddf000-b7de7000 r-xp 00000000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7de7000-b7de8000 r--p 00007000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7de8000-b7de9000 rw-p 00008000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7de9000-b7dfc000 r-xp 00000000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7dfc000-b7dfd000 r--p 00012000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7dfd000-b7dfe000 rw-p 00013000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7dfe000-b7e00000 rw-p b7dfe000 00:00 0 
b7e00000-b7e06000 r-xp 00000000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e06000-b7e07000 r--p 00005000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e07000-b7e08000 rw-p 00006000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7e08000-b7e09000 rw-p b7e08000 00:00 0 
b7e09000-b7f33000 r-xp 00000000 fe:00 7874349    /lib/libc-2.6.1.so
b7f33000-b7f35000 r--p 0012a000 fe:00 7874349    /lib/libc-2.6.1.so
b7f35000-b7f36000 rw-p 0012c000 fe:00 7874349    /lib/libc-2.6.1.so
b7f36000-b7f3a000 rw-p b7f36000 00:00 0 
b7f53000-b7f5d000 r-xp 00000000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f5d000-b7f5e000 r--p 00009000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f5e000-b7f5f000 rw-p 0000a000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f5f000-b7f60000 rw-p b7f5f000 00:00 0 
b7f60000-b7f7a000 r-xp 00000000 fe:00 7875733    /lib/ld-2.6.1.so
b7f7a000-b7f7b000 r--p 00019000 fe:00 7875733    /lib/ld-2.6.1.so
b7f7b000-b7f7c000 rw-p 0001a000 fe:00 7875733    /lib/ld-2.6.1.so
bf867000-bf87c000 rw-p bffeb000 00:00 0          [stack]
ffffe000-fffff000 r-xp 00000000 00:00 0          [vdso]
Aborted
muelli@rootbox ~ $ 



So it doesn't matter whether the command is run by root or not and the glob doens't expand.

Note that the "." isn't the culprit but rather the globbing asterisk:
muelli@rootbox ~ $  locate 'about*desktop'
/opt/gnome2/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about.desktop
/usr/share/applications/gnome-about-me.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/.svn/text-base/gnome-about.desktop.in.in.svn-base
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in.in
*** glibc detected *** locate: double free or corruption (fasttop): 0x080538d0 ***
======= Backtrace: =========
/lib/libc.so.6[0xb7e3aa00]
/lib/libc.so.6(cfree+0x89)[0xb7e3c6f9]
locate[0x804b218]
======= Memory map: ========
08048000-08050000 r-xp 00000000 fe:00 8629447    /usr/bin/slocate
08050000-08051000 r--p 00007000 fe:00 8629447    /usr/bin/slocate
08051000-08052000 rw-p 00008000 fe:00 8629447    /usr/bin/slocate
08052000-08073000 rw-p 08052000 00:00 0          [heap]
b7c00000-b7c21000 rw-p b7c00000 00:00 0 
b7c21000-b7d00000 ---p b7c21000 00:00 0 
b7da1000-b7da9000 r-xp 00000000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7da9000-b7daa000 r--p 00007000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7daa000-b7dab000 rw-p 00008000 fe:00 7875559    /lib/libnss_files-2.6.1.so
b7dab000-b7db3000 r-xp 00000000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7db3000-b7db4000 r--p 00007000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7db4000-b7db5000 rw-p 00008000 fe:00 7875700    /lib/libnss_nis-2.6.1.so
b7db5000-b7dc8000 r-xp 00000000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7dc8000-b7dc9000 r--p 00012000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7dc9000-b7dca000 rw-p 00013000 fe:00 7875699    /lib/libnsl-2.6.1.so
b7dca000-b7dcc000 rw-p b7dca000 00:00 0 
b7dcc000-b7dd2000 r-xp 00000000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7dd2000-b7dd3000 r--p 00005000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7dd3000-b7dd4000 rw-p 00006000 fe:00 7875702    /lib/libnss_compat-2.6.1.so
b7dd4000-b7dd5000 rw-p b7dd4000 00:00 0 
b7dd5000-b7eff000 r-xp 00000000 fe:00 7874349    /lib/libc-2.6.1.so
b7eff000-b7f01000 r--p 0012a000 fe:00 7874349    /lib/libc-2.6.1.so
b7f01000-b7f02000 rw-p 0012c000 fe:00 7874349    /lib/libc-2.6.1.so
b7f02000-b7f06000 rw-p b7f02000 00:00 0 
b7f1f000-b7f29000 r-xp 00000000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f29000-b7f2a000 r--p 00009000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f2a000-b7f2b000 rw-p 0000a000 fe:00 9096215    /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/libgcc_s.so.1
b7f2b000-b7f2c000 rw-p b7f2b000 00:00 0 
b7f2c000-b7f46000 r-xp 00000000 fe:00 7875733    /lib/ld-2.6.1.so
b7f46000-b7f47000 r--p 00019000 fe:00 7875733    /lib/ld-2.6.1.so
b7f47000-b7f48000 rw-p 0001a000 fe:00 7875733    /lib/ld-2.6.1.so
bff33000-bff48000 rw-p bffeb000 00:00 0          [stack]
ffffe000-fffff000 r-xp 00000000 00:00 0          [vdso]
Aborted
muelli@rootbox ~ $  locate gnome-about.desktop.in.in #this doesn't crash
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/.svn/text-base/gnome-about.desktop.in.in.svn-base
/home/muelli/svn/gnome2/gnome-desktop/gnome-about/gnome-about.desktop.in.in
muelli@rootbox ~ $ 

I tried to reopen the bug as I've provided the requested information but I'm not allowed to...
Comment 6 Kevin Parent 2008-09-17 04:32:18 UTC
Reopened.  I supplied the requested info in comment #4

I have this issue on several gentoo systems - athlon-xp, prescott, K8.

Today I did a grp install with the livecd and guess what?  No issue... YET!
Comment 7 Fab 2009-01-14 09:32:01 UTC
Created attachment 178460 [details]
reproduce crash

Same problem here. I tried to run /usr/bin/locate into gdb but I got a 'permission denied'. Should I be in the locate group ?
Comment 8 Samuli Suominen (RETIRED) gentoo-dev 2010-12-18 17:14:28 UTC
slocate is out of tree, use mlocate