Index: include/bn.h
===================================================================
--- include/bn.h	(revision 63617)
+++ include/bn.h	(working copy)
@@ -2260,7 +2260,8 @@
  * @return -3	Intersection exists, < A (t is returned)
  * @return -2	Intersection exists, > B (t is returned)
  * @return -1	Lines do not intersect
- * @return 0	Lines are co-linear (t for A is returned)
+ * @return 0	Lines are co-linear (t for closest point/whichever is on the
+                                     ray returned)
  * @return 1	Intersection at vertex A
  * @return 2	Intersection at vertex B
  * @return 3	Intersection between A and B
@@ -2267,13 +2268,13 @@
  *
  * @par Implicit Returns -
  *
- * t When explicit return >= 0, t is the parameter that describes the
- * intersection of the line and the line segment.  The actual
- * intersection coordinates can be found by solving P + t * D.
- * However, note that for return codes 1 and 2 (intersection exactly
- * at a vertex), it is strongly recommended that the original values
- * passed in A or B are used instead of solving P + t * D, to prevent
- * numeric error from creeping into the position of the endpoints.
+ * t When explicit return >= 0, t is the distance from P to the
+ * intersection point.  The actual intersection coordinates can be
+ * found by solving P + t.  However, note that for return codes 1 and
+ * 2 (intersection exactly at a vertex), it is strongly recommended
+ * that the original values passed in A or B are used instead of
+ * solving P + t, to prevent numeric error from creeping into the
+ * position of the endpoints.
  *
  * XXX should probably be called bn_isect_line3_lseg3()
  * XXX should probably be changed to return dist[2]
Index: src/libbn/plane.c
===================================================================
--- src/libbn/plane.c	(revision 63617)
+++ src/libbn/plane.c	(working copy)
@@ -1457,6 +1457,7 @@
 
 	dist1 = fabs(dist1); /* sanity */
 	VSCALE(isect_pt, d_unit, dist1);
+	VADD2(isect_pt, isect_pt, p);
 	VSUB2(a_to_isect_pt, isect_pt, a);
 	VSUB2(b_to_isect_pt, isect_pt, b);
 
Index: src/libbn/tests/CMakeLists.txt
===================================================================
--- src/libbn/tests/CMakeLists.txt	(revision 63617)
+++ src/libbn/tests/CMakeLists.txt	(working copy)
@@ -236,22 +236,13 @@
 # numbers separated by commas.
 
 add_test(bn_plane_isect_line_lseg_case-4_1   tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,0 0,0,0 -4 0)
-# This test fails because it thinks that there is an intersection
-# between a and b, even though the intersection is less than a.
-add_test(bn_plane_isect_line_lseg_case-3_1   tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,1 0,0,5 -3 6)
-# This test fails because it does not return the correct t.
-add_test(bn_plane_isect_line_lseg_case-2_1   tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,-5 0,0,1 -2 6)
+add_test(bn_plane_isect_line_lseg_case-3_1   tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,1 0,0,5 -3 8.660)
+add_test(bn_plane_isect_line_lseg_case-2_1   tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,-5 0,0,-1 -2 8.660)
 add_test(bn_plane_isect_line_lseg_case-1_1   tester_bn_plane_isect 1 -5,-5,-5 1,1,1 -5,-5,-6 0,0,-1 -1 0)
-# This test fails because it does not return the correct t for a
-add_test(bn_plane_isect_line_lseg_case0_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 1,1,1 5,5,5 0 6)
-# This test fails because it thinks that there is an intersection
-# between a and be even though they intersect at a
-add_test(bn_plane_isect_line_lseg_case1_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,0 0,0,5 1 5)
-# This test fails because it thinks that the intersection is past b
-# even though it is at b
-add_test(bn_plane_isect_line_lseg_case2_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,-5 0,0,0 2 5)
-# This test fails because it does not return the correct t for the intersection
-add_test(bn_plane_isect_line_lseg_case3_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,-5 0,0,5 3 5)
+add_test(bn_plane_isect_line_lseg_case0_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 1,1,1 5,5,5 0 10.392)
+add_test(bn_plane_isect_line_lseg_case1_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,0 0,0,5 1 8.660)
+add_test(bn_plane_isect_line_lseg_case2_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,-5 0,0,0 2 8.660)
+add_test(bn_plane_isect_line_lseg_case3_1    tester_bn_plane_isect 1 -5,-5,-5 1,1,1 0,0,-5 0,0,5 3 8.660)
 
 # For function #2 (bn_isect_lseg3_lseg3), the <args> format is as follows:
 #
