melib: correct out of bounds access

embed
Manos Pitsidianakis 2019-05-26 18:44:40 +03:00
parent c6674a294d
commit 03317d74ca
Signed by: Manos Pitsidianakis
GPG Key ID: 73627C2F690DF710
1 changed files with 1 additions and 1 deletions

View File

@ -695,7 +695,7 @@ impl Threads {
*/
let mut c_idx = 0;
loop {
if c_idx == thread_nodes[&idx].children.len() {
if c_idx >= thread_nodes[&idx].children.len() {
break;
}
let c = thread_nodes[&idx].children[c_idx];