diff options
author | Harald Eilertsen <haraldei@anduin.net> | 2018-12-20 14:15:38 +0100 |
---|---|---|
committer | Harald Eilertsen <haraldei@anduin.net> | 2018-12-20 14:15:38 +0100 |
commit | fc5877b7b8095a6ec0bb11eba2cd16c2ce5e2feb (patch) | |
tree | 6f11f7af35848166e8c0543aac7e5ca771abebca /src | |
parent | 582c59c8c47df77439b6c6800b658bdb54dbfeaf (diff) | |
download | trriggy-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.rs | 2 |
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; } |