dect
/
asterisk
Archived
13
0
Fork 0

Fix an off by one error that caused a unit test to occasionally crash.

git-svn-id: http://svn.digium.com/svn/asterisk/trunk@269711 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
russell 2010-06-10 13:17:51 +00:00
parent 8f76dde74d
commit 7b0ae9176b
1 changed files with 1 additions and 1 deletions

View File

@ -241,7 +241,7 @@ AST_TEST_DEFINE(heap_test_3)
i = test_size / 10;
while (i--) {
random_index = ast_random() % test_size - 1;
random_index = ast_random() % test_size;
node = ast_heap_remove(h, &nodes[random_index]);
if (nodes[random_index].val != node->val){
ast_test_status_update(test, "Failed to remove what we expected to\n");