Csound Csound-dev Csound-tekno Search About

Re: Segmentation fault...

Date2006-01-13 14:52
FromMichael Gogins
SubjectRe: Segmentation fault...
Csound is a programming language, not an application. Programming languages, as a rule, cannot infer all paths to fatal error and so I think you are asking too much. For example, even in garbage collected languages such as Java, writing to an uninitialized reference will cause an access violation. This is the language user's programming mistake, not the language designer's programming mistake.

Regards,
Mike

-----Original Message-----
>From: Erik de Castro Lopo 
>Sent: Jan 13, 2006 2:03 AM
>To: csound@lists.bath.ac.uk
>Subject: Re: [Csnd] Segmentation fault...
>
>Anthony Kozar wrote:
>
>
>
>> The segmentation fault means that
>> Csound tried to access a memory location that did not belong to it. 
>
>Programs really should validate their inputs. I my own programs,
>I consider any segfault to be a bug that needs to be fixed.
>
>> That is
>> almost certainly the old table that was overwritten, the space for which has
>> been returned to the operating system.
>> 
>> The solution is to not replace a table if there are any notes currently
>> using it.
>
>If this is the case then shouldn't csound consider that an 
>error in the input file and bomb out forcing the user to
>fix the input file?
>
>Erik
>-- 
>+-----------------------------------------------------------+
>  Erik de Castro Lopo
>+-----------------------------------------------------------+
>"I could never learn to use C++, because of the completely 
>overwhelming desire to redesign the language every time I tried 
>to use it, but this is the normal, healthy reaction to C++."
>-- Erik Naggum
>-- 
>Send bugs reports to this list.
>To unsubscribe, send email to csound-unsubscribe@lists.bath.ac.uk