Philip Rowlands wrote: > Adam Waltman wrote: > >k13 coreutils-5.94 # src/shred --remove --zero adam adam1 > >Segmentation fault > > > >It seems that he shred itself is the culprit. > >I have no real experience in programming in Linux, > >but I have installed gdb and tried to squeeze something out of it > >without any success. Could you instruct me how to trace this segfault? > > You might try > $ gdb -x <( printf "run\nbt" ) --args src/shred --remove --zero adam adam1 > > and look at the stack trace, or
Good suggestion. But I think that needs another \n in the printf. Doesn't it? gdb -x <( printf "run\nbt\nq\n" ) --args src/shred --remove --zero adam adam1 In any case the idea is to run gdb on the program, run it, hope it crashes the same as outside of the debugger, and then report what it found. Just in case the above does not work you would want something similar to this: gdb ../../src/shred run --remove --zero adam adam1 backtrace > $ strace src/shred --remove --zero adam adam1 > > and look what shred does just before crashing. Another good suggestion. It does not need the source to run. But I have been having poor luck lately finding core dump information with strace because the problems have not been near a system call. :-( Bob _______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils