summaryrefslogtreecommitdiffstats
path: root/googletest/src/gtest-internal-inl.h
diff options
context:
space:
mode:
authorGennadiy Civil <gennadiycivil@users.noreply.github.com>2018-08-15 15:37:15 (GMT)
committerGitHub <noreply@github.com>2018-08-15 15:37:15 (GMT)
commit7e7e3a6f45db62d470c9d15b062582e9e95d3bcd (patch)
tree29039379de3d6fb3ef4c049d9b69faba9b4e5ccf /googletest/src/gtest-internal-inl.h
parentb50b2f775ed0268af9c83a96b285e296778d0743 (diff)
parent997d343dd680e541ef96ce71ee54a91daf2577a0 (diff)
downloadgoogletest-7e7e3a6f45db62d470c9d15b062582e9e95d3bcd.zip
googletest-7e7e3a6f45db62d470c9d15b062582e9e95d3bcd.tar.gz
googletest-7e7e3a6f45db62d470c9d15b062582e9e95d3bcd.tar.bz2
Merge branch 'master' into patch-1
Diffstat (limited to 'googletest/src/gtest-internal-inl.h')
-rw-r--r--googletest/src/gtest-internal-inl.h17
1 files changed, 12 insertions, 5 deletions
diff --git a/googletest/src/gtest-internal-inl.h b/googletest/src/gtest-internal-inl.h
index e77c8b6..43effbf 100644
--- a/googletest/src/gtest-internal-inl.h
+++ b/googletest/src/gtest-internal-inl.h
@@ -27,10 +27,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Utility functions and classes used by the Google C++ testing framework.
-//
-// Author: wan@google.com (Zhanyong Wan)
-//
+// Utility functions and classes used by the Google C++ testing framework.//
// This file contains purely Google Test's internal implementation. Please
// DO NOT #INCLUDE IT IN A USER PROGRAM.
@@ -446,6 +443,16 @@ class OsStackTraceGetter : public OsStackTraceGetterInterface {
virtual void UponLeavingGTest();
private:
+#if GTEST_HAS_ABSL
+ Mutex mutex_; // Protects all internal state.
+
+ // We save the stack frame below the frame that calls user code.
+ // We do this because the address of the frame immediately below
+ // the user code changes between the call to UponLeavingGTest()
+ // and any calls to the stack trace code from within the user code.
+ void* caller_frame_ = nullptr;
+#endif // GTEST_HAS_ABSL
+
GTEST_DISALLOW_COPY_AND_ASSIGN_(OsStackTraceGetter);
};
@@ -984,7 +991,7 @@ bool ParseNaturalNumber(const ::std::string& str, Integer* number) {
const bool parse_success = *end == '\0' && errno == 0;
- // TODO(vladl@google.com): Convert this to compile time assertion when it is
+ // FIXME: Convert this to compile time assertion when it is
// available.
GTEST_CHECK_(sizeof(Integer) <= sizeof(parsed));