[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Check for null pointer
From: |
Dan Eble |
Subject: |
Check for null pointer |
Date: |
Wed, 17 Aug 2011 01:15:04 -0400 |
I think the following code should check that ev is not null before
dereferencing it. This might be a factor in a segfault I saw. (Sorry to be so
vague, but I am not going to build lilypond to test the theory. It would take
a credible threat of violence to change my mind.) A grep suggests that there
may be other similar cases.
void
Dispatcher::dispatch (SCM sev)
{
Stream_event *ev = unsmob_stream_event (sev);
SCM class_symbol = ev->get_property ("class");
--
Dan
- Check for null pointer,
Dan Eble <=
- Re: Check for null pointer, Carl Sorensen, 2011/08/17
- Re: Check for null pointer, Dan Eble, 2011/08/18
- Re: Check for null pointer, Carl Sorensen, 2011/08/18
- Re: Check for null pointer, Dan Eble, 2011/08/20
- Re: Check for null pointer, Reinhold Kainhofer, 2011/08/20
- Re: Check for null pointer, Dan Eble, 2011/08/20
- Re: Check for null pointer, Dan Eble, 2011/08/20
- Re: Check for null pointer, Reinhold Kainhofer, 2011/08/21