aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorHarald Eilertsen <haraldei@anduin.net>2018-12-20 14:15:38 +0100
committerHarald Eilertsen <haraldei@anduin.net>2018-12-20 14:15:38 +0100
commitfc5877b7b8095a6ec0bb11eba2cd16c2ce5e2feb (patch)
tree6f11f7af35848166e8c0543aac7e5ca771abebca /src
parent582c59c8c47df77439b6c6800b658bdb54dbfeaf (diff)
downloadtrriggy-fc5877b7b8095a6ec0bb11eba2cd16c2ce5e2feb.tar.gz
trriggy-fc5877b7b8095a6ec0bb11eba2cd16c2ce5e2feb.tar.bz2
trriggy-fc5877b7b8095a6ec0bb11eba2cd16c2ce5e2feb.zip
Fix off-by one error when reaching end of sample.
Diffstat (limited to 'src')
-rw-r--r--src/main.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs
index 0210df8..0c7e74d 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -56,7 +56,7 @@ impl Trigger {
self.sample_pos += 1;
}
- if self.sample_pos > self.sample.len() {
+ if self.sample_pos == self.sample.len() {
self.playing = false;
}