# HG changeset patch # User Andreas Weber # Date 1420166856 28800 # Node ID 8dbd557421124a6d67ab3ede6428541e6c2aacaf # Parent 93dd3457eef93356aea23b196986d56af14d2595 Prevent segfault when video card has insufficient OpenGL support (bug #41747). * __init_fltk__.cc: Check canvas->can_do () before trying to display plot. diff --git a/libinterp/dldfcn/__init_fltk__.cc b/libinterp/dldfcn/__init_fltk__.cc --- a/libinterp/dldfcn/__init_fltk__.cc +++ b/libinterp/dldfcn/__init_fltk__.cc @@ -929,7 +929,9 @@ void show_canvas (void) { - if (fp.is_visible ()) + if (! canvas->can_do ()) + error ("unable to plot due to insufficient OpenGL support"); + else if (fp.is_visible ()) { canvas->show (); canvas->make_current ();