fix zero length dashed lines

targeted fix turns zero length line
into very short line.

R=egdaniel@google.com
Bug: skia:7387
Change-Id: Ic2a809d30d722f4e8f51d9205666dc1476a10067
Reviewed-on: https://skia-review.googlesource.com/84661
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
diff --git a/gm/strokes.cpp b/gm/strokes.cpp
index 7bd31c2..ed13d09 100644
--- a/gm/strokes.cpp
+++ b/gm/strokes.cpp
@@ -518,3 +518,18 @@
 
 DEF_GM( return new ZeroLenStrokesGM; )
 DEF_GM( return new TeenyStrokesGM; )
+
+DEF_SIMPLE_GM(zerolinedash, canvas, 256, 256) {
+    canvas->clear(SK_ColorWHITE);
+
+    SkPaint paint;
+    paint.setColor(SkColorSetARGB(255, 0, 0, 0));
+    paint.setStrokeWidth(11);
+    paint.setStrokeCap(SkPaint::kRound_Cap);
+    paint.setStrokeJoin(SkPaint::kBevel_Join);
+
+    SkScalar dash_pattern[] = {1, 5};
+    paint.setPathEffect(SkDashPathEffect::Make(dash_pattern, 2, 0));
+
+    canvas->drawLine(100, 100, 100, 100, paint);
+}