You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by sc...@apache.org on 2017/07/01 03:58:12 UTC
[trafficserver] branch master updated: SEGV in Diags when we try to
use Fatal macro
This is an automated email from the ASF dual-hosted git repository.
scw00 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new e62f3d3 SEGV in Diags when we try to use Fatal macro
e62f3d3 is described below
commit e62f3d3c5a00c48f0af6d1cc8a1165a1d6d78d32
Author: scw00 <61...@qq.com>
AuthorDate: Fri Jun 16 11:07:14 2017 +0800
SEGV in Diags when we try to use Fatal macro
---
proxy/Main.cc | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/proxy/Main.cc b/proxy/Main.cc
index 75d9fcc..28ff754 100644
--- a/proxy/Main.cc
+++ b/proxy/Main.cc
@@ -1644,12 +1644,9 @@ main(int /* argc ATS_UNUSED */, const char **argv)
main_thread->set_specific();
// Re-initialize diagsConfig based on records.config configuration
- if (diagsConfig) {
- RecDebugOff();
- delete (diagsConfig);
- }
- diagsConfig = new DiagsConfig("Server", DIAGS_LOG_FILENAME, error_tags, action_tags, true);
- diags = diagsConfig->diags;
+ DiagsConfig *old_log = diagsConfig;
+ diagsConfig = new DiagsConfig("Server", DIAGS_LOG_FILENAME, error_tags, action_tags, true);
+ diags = diagsConfig->diags;
RecSetDiags(diags);
diags->set_stdout_output(bind_stdout);
diags->set_stderr_output(bind_stderr);
@@ -1657,6 +1654,11 @@ main(int /* argc ATS_UNUSED */, const char **argv)
diags->dump();
}
+ if (old_log) {
+ delete (old_log);
+ old_log = nullptr;
+ }
+
DebugCapabilities("privileges"); // Can do this now, logging is up.
// Check if we should do mlockall()
--
To stop receiving notification emails like this one, please contact
['"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>'].