From: Luigi Rizzo Date: Wed, 2 Jul 2008 09:16:29 +0000 (+0000) Subject: prevent a segfault when trying to start the gui without any X-Git-Tag: 1.6.2.0-beta1~1816 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f26e7b97cbe9942e6a1731b58f4faaed9b32facb;p=thirdparty%2Fasterisk.git prevent a segfault when trying to start the gui without any specific configuration in oss.conf (reported by Klaus Darillion on the -video mailing list). git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@127330 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/console_video.c b/channels/console_video.c index a68a930f87..aa81215059 100644 --- a/channels/console_video.c +++ b/channels/console_video.c @@ -284,7 +284,7 @@ void fbuf_free(struct fbuf_t *b) */ int get_gui_startup(struct video_desc* env) { - return env->stayopen; + return env ? env->stayopen : 0; } #if 0