# HG changeset patch # User Matthew Wild # Date 1245623095 -3600 # Node ID 707793a758c49e566c4f3385586cb31593a7dc93 # Parent 983f96ebef0806ccaf79af991693e8a6d677025f readdate: Fix traceback when nothing is consumed from the input text diff -r 983f96ebef08 -r 707793a758c4 readdate.lua --- a/readdate.lua Sun Jun 21 23:24:25 2009 +0100 +++ b/readdate.lua Sun Jun 21 23:24:55 2009 +0100 @@ -13,7 +13,7 @@ if start and finish then remaining = (line:sub(1, start)..line:sub(finish, -1)):gsub("^[%s%p]+", ""):gsub("[%s%p]+$", ""); end - print(os.date("%c", ret).." ("..ret..")"..((#remaining>0 and (": "..remaining)) or "").." ["..start..","..finish.."]"); + print(os.date("%c", ret).." ("..ret..")"..((#remaining>0 and (": "..remaining)) or "").." ["..(start or "?")..","..(finish or "?").."]"); end end