Quantcast

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Eitan Adler-4
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: Eitan Adler <[hidden email]>
To: [hidden email], [hidden email]
Cc: "Klaus T. Aehlig" <[hidden email]>
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)
Date: Sun, 29 May 2011 23:58:13 +0000

 Hi,
 Fabian: Would it be possible for you to build the port with debugging
 symbols (WITH_DEBUG="yes" in /etc/make.conf or -DWITH_DEBUG as an
 argument to make) in order to get a useful backtrace? We are unable to
 reproduce the problem and this would help us to fix the issue.
 
 Klaus: the automailer didn't kick in, but this PR relates to your
 port: misc/findutils.
 
 
 --
 Eitan Adler
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Klaus Aehlig
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: "Klaus T. Aehlig" <[hidden email]>
To: Eitan Adler <[hidden email]>
Cc: [hidden email], [hidden email]
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core
 dumped)
Date: Mon, 30 May 2011 15:33:37 +0100

 Hi,
 
 I finally managed to reproduce the bug. It seems to be
 base-system specific; at least, all my attempts to reproduce
 it on my 8.2-STABLE amd64 machine failed.
 
 However, the following "worked". I took a fresh virtual machine
 and installed a minimal 7.3-RELEASE amd64[1]. Taking an up-to-date
 ports tree (as of this morning[2]) and installing misc/findutils from
 there produced a /usr/local/bin/gfind that would core dump.
 
 I got the following stack backtrace.
 
 # gdb /usr/local/bin/gfind gfind.core
 GNU gdb 6.1.1 [FreeBSD]
 Copyright 2004 Free Software Foundation, Inc.
 GDB is free software, covered by the GNU General Public License, and you are
 welcome to change it and/or distribute copies of it under certain conditions.
 Type "show copying" to see the conditions.
 There is absolutely no warranty for GDB.  Type "show warranty" for details.
 This GDB was configured as "amd64-marcel-freebsd"...
 Core was generated by `gfind'.
 Program terminated with signal 11, Segmentation fault.
 Reading symbols from /usr/local/lib/libintl.so.9...done.
 Loaded symbols for /usr/local/lib/libintl.so.9
 Reading symbols from /usr/local/lib/libiconv.so.3...done.
 Loaded symbols for /usr/local/lib/libiconv.so.3
 Reading symbols from /lib/libm.so.5...done.
 Loaded symbols for /lib/libm.so.5
 Reading symbols from /lib/libc.so.7...done.
 Loaded symbols for /lib/libc.so.7
 Reading symbols from /libexec/ld-elf.so.1...done.
 Loaded symbols for /libexec/ld-elf.so.1
 #0  0x0000000800b6f620 in telldir () from /lib/libc.so.7
 (gdb) where
 #0  0x0000000800b6f620 in telldir () from /lib/libc.so.7
 #1  0x000000000042467d in fts_build (sp=0x800d0e080, type=3) at fts.c:1356
 #2  0x000000000042338f in fts_read (sp=0x800d0e080) at fts.c:891
 #3  0x000000000040420a in find (arg=0x7fffffffeb40 ".") at ftsfind.c:567
 #4  0x000000000040431f in process_all_startpoints (argc=0, argv=0x7fffffffebe8) at ftsfind.c:632
 #5  0x000000000040448a in main (argc=1, argv=0x7fffffffebe0) at ftsfind.c:725
 (gdb)
 
 I'll investigate further.
 
 Best,
 Klaus
 
 
 
 [1] Using FreeBSD-7.3-RELEASE-amd64-disc1.iso
 MD5 (FreeBSD-7.3-RELEASE-amd64-disc1.iso) = 7c5049d15a95d9e0dd5eca013d1086b8
 
 [2] ctm cvs-cur 17507
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Eitan Adler-4
In reply to this post by Eitan Adler-4
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: Eitan Adler <[hidden email]>
To: [hidden email]
Cc:  
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)
Date: Mon, 30 May 2011 15:13:37 +0000

 ---------- Forwarded message ----------
 From: Klaus T. Aehlig <[hidden email]>
 Date: Mon, May 30, 2011 at 2:33 PM
 Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11
 (core dumped)
 To: Eitan Adler <[hidden email]>
 Cc: [hidden email], [hidden email]
 
 
 
 Hi,
 
 I finally managed to reproduce the bug. It seems to be
 base-system specific; at least, all my attempts to reproduce
 it on my 8.2-STABLE amd64 machine failed.
 
 However, the following "worked". I took a fresh virtual machine
 and installed a minimal 7.3-RELEASE amd64[1]. Taking an up-to-date
 ports tree (as of this morning[2]) and installing misc/findutils from
 there produced a /usr/local/bin/gfind that would core dump.
 
 I got the following stack backtrace.
 
 # gdb /usr/local/bin/gfind gfind.core
 GNU gdb 6.1.1 [FreeBSD]
 Copyright 2004 Free Software Foundation, Inc.
 GDB is free software, covered by the GNU General Public License, and you ar=
 e
 welcome to change it and/or distribute copies of it under certain condition=
 s.
 Type "show copying" to see the conditions.
 There is absolutely no warranty for GDB. =C2=A0Type "show warranty" for det=
 ails.
 This GDB was configured as "amd64-marcel-freebsd"...
 Core was generated by `gfind'.
 Program terminated with signal 11, Segmentation fault.
 Reading symbols from /usr/local/lib/libintl.so.9...done.
 Loaded symbols for /usr/local/lib/libintl.so.9
 Reading symbols from /usr/local/lib/libiconv.so.3...done.
 Loaded symbols for /usr/local/lib/libiconv.so.3
 Reading symbols from /lib/libm.so.5...done.
 Loaded symbols for /lib/libm.so.5
 Reading symbols from /lib/libc.so.7...done.
 Loaded symbols for /lib/libc.so.7
 Reading symbols from /libexec/ld-elf.so.1...done.
 Loaded symbols for /libexec/ld-elf.so.1
 #0 =C2=A00x0000000800b6f620 in telldir () from /lib/libc.so.7
 (gdb) where
 #0 =C2=A00x0000000800b6f620 in telldir () from /lib/libc.so.7
 #1 =C2=A00x000000000042467d in fts_build (sp=3D0x800d0e080, type=3D3) at ft=
 s.c:1356
 #2 =C2=A00x000000000042338f in fts_read (sp=3D0x800d0e080) at fts.c:891
 #3 =C2=A00x000000000040420a in find (arg=3D0x7fffffffeb40 ".") at ftsfind.c=
 :567
 #4 =C2=A00x000000000040431f in process_all_startpoints (argc=3D0,
 argv=3D0x7fffffffebe8) at ftsfind.c:632
 #5 =C2=A00x000000000040448a in main (argc=3D1, argv=3D0x7fffffffebe0) at ft=
 sfind.c:725
 (gdb)
 
 I'll investigate further.
 
 Best,
 Klaus
 
 
 
 [1] Using FreeBSD-7.3-RELEASE-amd64-disc1.iso
 MD5 (FreeBSD-7.3-RELEASE-amd64-disc1.iso) =3D 7c5049d15a95d9e0dd5eca013d108=
 6b8
 
 [2] ctm cvs-cur 17507
 
 
 
 --=20
 Eitan Adler
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Klaus Aehlig
In reply to this post by Eitan Adler-4
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: "Klaus T. Aehlig" <[hidden email]>
To: Eitan Adler <[hidden email]>
Cc: [hidden email], [hidden email]
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core
 dumped)
Date: Mon, 30 May 2011 18:46:12 +0100

 Hi,
 
 further investigations (thanks to Helmut Grohne who helped me) on my
 7.3-RELEASE virtual machine showed that gfind does the following sequence
 of libc-calls, which seg faults on 7.3-RELEASE, but not on 8.2-STABLE:
 open, fdopendir, readdir.
 
 I could construct the following minimal example, which I belive should
 not cause a segmentation fault, but does on 7.3-RELEASE.
 
 # uname -a
 FreeBSD  7.3-RELEASE FreeBSD 7.3-RELEASE #0: Sun Mar 21 05:25:24 UTC 2010     [hidden email]:/usr/obj/usr/src/sys/GENERIC  amd64
 # cat testfdopendir.c
 #include <fcntl.h>
 #include <sys/types.h>
 #include <dirent.h>
 
 int main(int argc, char **argv) {
         DIR *dirp;
         int fd;
 
         fd = open(".",  O_RDONLY);
         dirp = fdopendir(fd);
         (void) readdir(dirp);
 
 }
 
 # cc testfdopendir.c
 testfdopendir.c: In function 'main':
 testfdopendir.c:10: warning: assignment makes pointer from integer without a cast
 # ./a.out
 Segmentation fault (core dumped)
 #
 
 Also note the compiler warning, that suggests that including <sys/types.h>
 and <dirent.h> does not seem to suffice---as opposed what the man page
 tells---to get the fdopendir prototype. I believe that is a bug in
 RELENG_7_3_0.
 
 Eitan: can you please inform the appropriate maintainer about this
 bug (if it is not fixed already in an errata for 7.3-RELEASE)?
 
 Unfortunately, the obvious patch does not yet solve the problem, so I
 have to investigate further. But I thought, I'd still report back
 the problem with the libc headers.
 
 Best,
 Klaus
 
 
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Klaus Aehlig
In reply to this post by Eitan Adler-4
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: "Klaus T. Aehlig" <[hidden email]>
To: Eitan Adler <[hidden email]>
Cc: [hidden email], [hidden email]
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core
 dumped)
Date: Mon, 30 May 2011 22:47:23 +0100

 --yrj/dFKFPuw6o+aM
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 
 
 Hi again,
 
 the misssing prototype _was_ the problem. I just got confused
 by the various #ifdef's in that file. On my 7.3-RELEASE
 adding the attached patch to the files directory (and bumping
 PORTREVISION) solves the problem.
 
 Fabian: can you please verify that this solves the problem
 for you as well?
 
 Eitan: can you please assign this PR to someone so that the
 change gets committed (or commit it yourself)?
 
 Best,
 Klaus
 
 PS:
 The incomplete header on 7.3-RELEASE should be fixed
 nevertheless. Whom to forward this observation?
 
 --yrj/dFKFPuw6o+aM
 Content-Type: text/x-csrc; charset=us-ascii
 Content-Disposition: attachment; filename="patch-gnulib__lib__fdopendir.c"
 
 --- gnulib/lib/fdopendir.c.orig 2011-04-02 15:37:38.000000000 +0000
 +++ gnulib/lib/fdopendir.c 2011-05-30 21:05:02.000000000 +0000
 @@ -182,9 +182,11 @@
 
  # include <errno.h>
  # include <sys/stat.h>
 +# include <dirent.h>
 
  # undef fdopendir
 
 +extern DIR *fdopendir(int);
  /* Like fdopendir, but work around GNU/Hurd bug by validating FD.  */
 
  DIR *
 
 --yrj/dFKFPuw6o+aM--
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Fabian Wenk
In reply to this post by Eitan Adler-4
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: Fabian Wenk <[hidden email]>
To: "Klaus T. Aehlig" <[hidden email]>
Cc: Eitan Adler <[hidden email]>, [hidden email]
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core
 dumped)
Date: Tue, 31 May 2011 21:18:51 +0200

 Hello Klaus
 
 On 30.05.11 23:47, Klaus T. Aehlig wrote:
 > Fabian: can you please verify that this solves the problem
 > for you as well?
 
 Yes, this solves it on both my 7.3-RELEASE-p4 / amd64, and also on
 my friends 7.3-RELEASE-p2 / amd64 and on his 8.1-RELEASE / i386.
 
 
 bye
 Fabian
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)

Eitan Adler-4
In reply to this post by Eitan Adler-4
The following reply was made to PR ports/157274; it has been noted by GNATS.

From: Eitan Adler <[hidden email]>
To: "Klaus T. Aehlig" <[hidden email]>
Cc: [hidden email], [hidden email]
Subject: Re: ports/157274: misc/finutils: gfind segmentation fault: 11 (core dumped)
Date: Wed, 1 Jun 2011 02:25:14 +0000

 Hi,
 
 I'm sorry I did not see this conversation until now.
 
 Firstly, great job on debugging this problem!
 
 Secondly, FreeBSD doesn't "assign" bugs, rather comitters take them.
 
 Thirdly, this patch appears to fix the issue for me as well on my
 virtual machine just add to the "verified" list :-)
 
 Fourthly, At this point you have a patch in the PR and it appears to
 be fix the issue. My understanding is that you would like added to the
 files/ directory of the port. If that is the case leave the PR as is
 and I will set it to the appropriate state. It may take a bit of time
 before a committer sees this patch. I will do what I can to
 facilitate. Unfortunately I can not commit this patch, as I am not a
 ports committer.
 
 > Eitan: can you please assign this PR to someone so that the
 > change gets committed (or commit it yourself)?
 >
 > Best,
 > Klaus
 >
 > PS:
 > The incomplete header on 7.3-RELEASE should be fixed
 > nevertheless. Whom to forward this observation?
 >
 
 
 
 --
 Eitan Adler
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Loading...