From: Mikko Rasa Date: Thu, 17 Jan 2013 14:27:03 +0000 (+0200) Subject: Fix an off-by-one comparison error X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=eab144208f380f638295efac3c5ef234dc39ac54;p=r2c2.git Fix an off-by-one comparison error --- diff --git a/source/libr2c2/track.cpp b/source/libr2c2/track.cpp index 4d8a8fc..f21aac4 100644 --- a/source/libr2c2/track.cpp +++ b/source/libr2c2/track.cpp @@ -288,7 +288,7 @@ void Track::break_links() Track *Track::get_link(unsigned i) const { - if(i>links.size()) + if(i>=links.size()) throw out_of_range("Track::get_link"); return links[i];