On 10/02/12 14:03, quoth Linda Walsh:
Greg Wooledge wrote:
I see a system message from the original posters program: Segmentation fault (core dumped) Finding it is left as an exercise to the reader. It is noted that many programs catch fatal signals in order to not leave evidence of their crashing on the user's system as coredumps are considered 'bad form'/unsightly.
I think there's a fundamental misunderstanding between the difference of an error code returned by a system call and the exit status of a process. They're two completely different things.
Just for fun, look at the man page for grep. It is advertised to return a 0, 1 or 2. The actual values of errno that might happen in the middle are a separate problem.
-- Time flies like the wind. Fruit flies like a banana. Stranger things have .0. happened but none stranger than this. Does your driver's license say Organ ..0 Donor?Black holes are where God divided by zero. Listen to me! We are all- 000 individuals! What if this weren't a hypothetical question? steveo at syslang.net