Review Board 1.7.16


Fixed intermittent crash when loading test_json.so

Review Request #2669 - Created July 11, 2013 and submitted

David Lee
/trunk
ASTERISK-21978
Reviewers
asterisk-dev
Asterisk
The JSON test attempted an overly clever use of RAII_VAR to run code
at the beginning and end of each test, in order to validate that no
JSON objects were leaked during the test.

The problem is that the validation code would run during the initial
load, when the tests were initialized. This happens during startup,
when other parts of the system might actively be allocating and
freeing JSON objects.

This patch changes the RAII_VAR to use the new
ast_test_register_{init,cleanup} functions to run the validations
properly.
Tests pass; used debug log to verify that _init and _cleanup ran on
each test.
Review request changed
Updated (Aug. 27, 2013, 10:18 a.m.)
  • changed from pending to submitted
Committed in revision 397706

https://reviewboard.asterisk.org/ runs on a server provided by Digium, Inc. and uses bandwidth donated to the open source Asterisk community by API Digital Communications in Huntsville, AL USA.
Please report problems with this site to asteriskteam@digium.com.