diff --git a/Plugin/Levelset.cpp b/Plugin/Levelset.cpp index 87a1b66c5be8f5ddf3ee444372ff9210070cac2e..82cb909b6fbfebbe269c35f0a76267faab9859df 100644 --- a/Plugin/Levelset.cpp +++ b/Plugin/Levelset.cpp @@ -1,4 +1,4 @@ -// $Id: Levelset.cpp,v 1.35 2007-09-11 15:29:01 geuzaine Exp $ +// $Id: Levelset.cpp,v 1.36 2007-09-15 16:20:49 geuzaine Exp $ // // Copyright (C) 1997-2007 C. Geuzaine, J.-F. Remacle // @@ -555,7 +555,7 @@ PView *GMSH_LevelsetPlugin::execute(PView *v) if(_valueView < 0) { w = v; } - else if(_valueView < 0 || _valueView > PView::list.size() - 1){ + else if(_valueView > PView::list.size() - 1){ Msg(GERROR, "View[%d] does not exist: reverting to View[%d]", _valueView, v->getIndex()); w = v; diff --git a/Plugin/StreamLines.cpp b/Plugin/StreamLines.cpp index d73a7dc76410278e6cb8b1bf93f9d56de57759af..4eb813e16757a180fc53c02b90ad93f0ebbf2039 100644 --- a/Plugin/StreamLines.cpp +++ b/Plugin/StreamLines.cpp @@ -1,4 +1,4 @@ -// $Id: StreamLines.cpp,v 1.31 2007-09-11 14:01:55 geuzaine Exp $ +// $Id: StreamLines.cpp,v 1.32 2007-09-15 16:20:49 geuzaine Exp $ // // Copyright (C) 1997-2007 C. Geuzaine, J.-F. Remacle // @@ -372,7 +372,7 @@ PView *GMSH_StreamLinesPlugin::execute(PView *v) PView *v1 = getView(iView, v); if(!v1) return v; - PView *v2 = getView(dView, v); + PView *v2 = (dView < 0) ? 0 : getView(dView, v); return GenerateView(v1, v2); }