summaryrefslogtreecommitdiff
path: root/src/guile
diff options
context:
space:
mode:
authorLudovic Courtès2015-03-06 11:34:34 +0100
committerLudovic Courtès2015-03-06 11:34:34 +0100
commitee4390c437d9f9672bf8ef702ddc05fc5cdc1069 (patch)
tree65008e525350b44a27e0f1c6dd9772a784d11e08 /src/guile
parentc7be66d819c2d339cf0c580d9da52005caad0397 (diff)
downloadskribilo-ee4390c437d9f9672bf8ef702ddc05fc5cdc1069.tar.gz
skribilo-ee4390c437d9f9672bf8ef702ddc05fc5cdc1069.tar.lz
skribilo-ee4390c437d9f9672bf8ef702ddc05fc5cdc1069.zip
Fix off-by-one in 'substring' call in 'ast-location'.
* src/guile/skribilo/location.scm (ast-location): Fix off-by-one in 'substring' call.
Diffstat (limited to 'src/guile')
-rw-r--r--src/guile/skribilo/location.scm4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/guile/skribilo/location.scm b/src/guile/skribilo/location.scm
index fa88b18..7605600 100644
--- a/src/guile/skribilo/location.scm
+++ b/src/guile/skribilo/location.scm
@@ -1,7 +1,7 @@
;;; location.scm -- Skribilo source location.
;;; -*- coding: iso-8859-1 -*-
;;;
-;;; Copyright 2005, 2007, 2009, 2010, 2012, 2013 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright 2005, 2007, 2009, 2010, 2012, 2013, 2015 Ludovic Courtès <ludo@gnu.org>
;;; Copyright 2003, 2004 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;
;;;
@@ -63,7 +63,7 @@
(lenf (string-length fname))
(file (if (and (string-prefix? pwd fname len)
(> lenf len))
- (substring fname len (+ 1 (string-length fname)))
+ (substring fname len (string-length fname))
fname)))
(format #f "~a, line ~a" file line))
"no source location")))