[Lemon-commits] ladanyi: r3372 - glemon/branches/akos

Lemon SVN svn at lemon.cs.elte.hu
Thu Nov 8 18:21:53 CET 2007


Author: ladanyi
Date: Thu Nov  8 18:21:53 2007
New Revision: 3372

Modified:
   glemon/branches/akos/gdc-broken_edge.cc

Log:
Ported r3192 from trunk.

Modified: glemon/branches/akos/gdc-broken_edge.cc
==============================================================================
--- glemon/branches/akos/gdc-broken_edge.cc	(original)
+++ glemon/branches/akos/gdc-broken_edge.cc	Thu Nov  8 18:21:53 2007
@@ -93,7 +93,10 @@
   XY unit_vector_in_dir(head-center);
   double length=sqrt( unit_vector_in_dir.normSquare() );
 
-  unit_vector_in_dir/=length;
+  if(length!=0)
+    {
+      unit_vector_in_dir/=length;
+    }
 
   // update the arrow
   drawArrow(unit_vector_in_dir);



More information about the Lemon-commits mailing list