From 657a92e84ecad4f066043d9468be896041a97d23 Mon Sep 17 00:00:00 2001 From: jazzpi Date: Mon, 30 Mar 2015 12:45:46 +0200 Subject: [PATCH] handle range starting at 0 (fixes #30) --- lib/command.coffee | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/command.coffee b/lib/command.coffee index 0b5849b..1839086 100644 --- a/lib/command.coffee +++ b/lib/command.coffee @@ -102,6 +102,8 @@ class Command if off1? address1 += @parseOffset(off1) + address1 = 0 if address1 is -1 + if address1 < 0 or address1 > lastLine throw new CommandError('Invalid range')