-
Committer:
Alexey Kopytov
-
Date:
2013-06-11 14:55:57 UTC
-
Revision ID:
akopytov@gmail.com-20130611145557-nidin392ca2c00q7
Bug #1187040: Random Segmentation faults on fileio test
Fixed a race condition in the test termination code with respect to
--report-interval: the reporting thread might read a non-zero
report_interval value and call print_stats(). If report_interval is
changed to 0 by the master thread and the test's done() method called,
print_stats() could access some shared resources deallocated in
done().
Fixed by protecting report_interval with a separate mutex which is
locked on updates and during the check by reporting thread and
print_stats().