summaryrefslogtreecommitdiff
path: root/tests/test_event.c
diff options
context:
space:
mode:
authorMark Michelson <mmichelson@digium.com>2010-10-22 17:10:59 +0000
committerMark Michelson <mmichelson@digium.com>2010-10-22 17:10:59 +0000
commit3964b078dd4a49effcdf3b933184e200c649c1e5 (patch)
treed86b8112175e1ac749d42dccd683e350a8bf7fd8 /tests/test_event.c
parent64845d73c7cce5c3d5493aa0c360dc78561a655e (diff)
Merged revisions 292741 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r292741 | mmichelson | 2010-10-22 12:09:52 -0500 (Fri, 22 Oct 2010) | 12 lines Prevent multiple runs of event_sub_test from producing false failure results. The array of test subscriptions was declared "static," meaning that the data.count field would retain its value between runs of the test. After the first test run, this would result in false reports of test failures. I chose to just remove the "static" keyword from the structure since it's not a huge deal to construct this structure during each run of the test. Another alternative would have been to zero out the data.count fields of each test subscription instead. ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@292742 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'tests/test_event.c')
-rw-r--r--tests/test_event.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/test_event.c b/tests/test_event.c
index 82ef29bb3..4331d742f 100644
--- a/tests/test_event.c
+++ b/tests/test_event.c
@@ -253,7 +253,7 @@ AST_TEST_DEFINE(event_sub_test)
struct ast_event *event;
int i;
enum ast_event_subscriber_res sub_res;
- static struct {
+ struct {
struct ast_event_sub *sub;
struct event_sub_data data;
const unsigned int expected_count;