Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 99886 - sys-fs/squashfs-tools: mksquashfs segfualts when appending a non-existant dir to an existing squash image
Summary: sys-fs/squashfs-tools: mksquashfs segfualts when appending a non-existant dir...
Status: VERIFIED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: High critical (vote)
Assignee: Gentoo LiveCD Package Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-22 02:45 UTC by postmodern
Modified: 2005-09-09 06:12 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description postmodern 2005-07-22 02:45:56 UTC
After running "mksquashfs /src dest.squash -info -keep-as-directory" I found
that it both segfaulted and /src did exist. The utility should handle this case
properly and not segfault. Possibly relating to this, I found the resulting
dest.squash was completely corrupted with directory names of jibberish.

Reproducible: Always
Steps to Reproduce:
1. mksquashfs /exists dest.squash -info -keep-as-directory
2. mksquashfs /dosnt-exist dest.squash -info -keep-as-directory
3. mount -t squashfs -o loop dest.squash /mnt/floppy

Actual Results:  
step #2 segfaults and the contents of the squashfs image is corrupted

Expected Results:  
error message is printed by mksquashfs and the contents of the image are that of
/exists

Gentoo Base System version 1.6.13
Portage 2.0.51.22-r2 (default-linux/amd64/2004.3, gcc-3.4.3, glibc-2.3.5-r0,
2.6.12-gentoo-r6 x86_64)
=================================================================
System uname: 2.6.12-gentoo-r6 x86_64 AMD Athlon(tm) 64 Processor 3400+
dev-lang/python:     2.3.5
sys-apps/sandbox:    1.2.10
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5
sys-devel/binutils:  2.15.92.0.2-r10
sys-devel/libtool:   1.5.18-r1
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-pipe -O3 -march=k8"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/
/usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/
/usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-pipe -O3 -march=k8"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X aac alsa avi berkdb bitmap-fonts cdr crypt curl dvd encode esd fam
flac foomaticdb fortran gif gnome gpm gstreamer gtk gtk2 guile imagemagick imlib
ipv6 java jpeg libvisual libwww lzw lzw-tiff mad motif mp3 mpeg multilib ncurses
network nls ogg oggvorbis opengl pam pdflib perl png python quicktime readline
samba sdl softmmu speex spell sqlite ssl tcltk tcpd tetex theora tiff
truetype-fonts type1-fonts usb userlocales vorbis xine xml xml2 xmms xpm xv zlib
userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS
Comment 1 Chris Gianelloni (RETIRED) gentoo-dev 2005-07-22 06:31:15 UTC
I just added squashfs-tools 2.2 into portage.  Can you see if this resolves your
problem, please?
Comment 2 postmodern 2005-07-22 06:36:06 UTC
Will do when it gets into the portage mirrors.
Comment 3 postmodern 2005-08-16 20:38:26 UTC
Tested, it does not segfault but still produces a squashfs image when the src
does not exist.
Comment 4 Chris Gianelloni (RETIRED) gentoo-dev 2005-09-09 05:58:27 UTC
This should be fixed in 2.2_p2 ebuild... Thanks to the author for being so quick
and making a new version for me... ;]
Comment 5 postmodern 2005-09-09 06:12:27 UTC
Tested, works perfectly.