You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by zw...@apache.org on 2015/04/12 19:34:25 UTC
[1/2] trafficserver git commit: TS-3516 Fix various compile warnings
with latest versions of clang
Repository: trafficserver
Updated Branches:
refs/heads/master 818a8d754 -> d0d30f8be
TS-3516 Fix various compile warnings with latest versions of clang
Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/5fae5303
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/5fae5303
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/5fae5303
Branch: refs/heads/master
Commit: 5fae53034847334b2958b7516c969d344627de29
Parents: 818a8d7
Author: Leif Hedstrom <zw...@apache.org>
Authored: Sun Apr 12 12:33:42 2015 -0500
Committer: Leif Hedstrom <zw...@apache.org>
Committed: Sun Apr 12 12:33:42 2015 -0500
----------------------------------------------------------------------
configure.ac | 11 ++++++++---
lib/Makefile.am | 2 +-
proxy/http/HttpTransact.cc | 2 +-
proxy/logging/LogObject.cc | 2 +-
proxy/logging/LogObject.h | 2 +-
5 files changed, 12 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/5fae5303/configure.ac
----------------------------------------------------------------------
diff --git a/configure.ac b/configure.ac
index 22ce1cf..4896e5c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -849,15 +849,16 @@ case $host_os_def in
])
AS_IF([test "x$ax_cv_c_compiler_vendor" = "xclang"], [
+ common_opt="-pipe -Wall -Qunused-arguments -Wno-deprecated-declarations"
debug_opt="-ggdb3 $common_opt -Qunused-arguments"
release_opt="-g $common_opt $optimizing_flags -fno-strict-aliasing -Qunused-arguments"
- cxx_opt="-Wno-invalid-offsetof -Qunused-arguments"
+ cxx_opt="-Wno-invalid-offsetof"
+ luajit_cflags="-Wno-parentheses-equality -Wno-tautological-compare"
])
AS_IF([test "x$ax_cv_c_compiler_vendor" = "xgnu"], [
# This is useful for finding odd conversions
# common_opt="-pipe -Wall -Wconversion -Wno-sign-conversion"
- ts_am_common_flags="-Wunused-parameter"
common_opt="-pipe -Wall"
debug_opt="-ggdb3 $common_opt"
release_opt="-g $common_opt $optimizing_flags -feliminate-unused-debug-symbols -fno-strict-aliasing"
@@ -874,6 +875,7 @@ case $host_os_def in
debug_opt="-g $common_opt"
release_opt="-g $common_opt $optimizing_flags -fno-strict-aliasing"
cxx_opt="-Wno-invalid-offsetof"
+ luajit_cflags="-Wno-parentheses-equality -Wno-tautological-compare"
], [
AC_MSG_WARN([clang is the only supported compiler on Darwin])
])
@@ -893,10 +895,11 @@ case $host_os_def in
freebsd|kfreebsd)
AS_IF([test "x$ax_cv_c_compiler_vendor" = "xclang"], [
- common_opt="-pipe -Wall -Qunused-arguments"
+ common_opt="-pipe -Wall -Wno-deprecated-declarations"
debug_opt="-ggdb3 $common_opt"
release_opt="-g $common_opt $optimizing_flags -feliminate-unused-debug-symbols -fno-strict-aliasing"
cxx_opt="-Wno-invalid-offsetof -Qunused-arguments"
+ luajit_cflags="-Wno-parentheses-equality -Wno-tautological-compare"
])
AS_IF([test "x$ax_cv_c_compiler_vendor" = "xgnu"], [
@@ -965,7 +968,9 @@ AM_CXXFLAGS="$ts_am_common_flags"
AC_SUBST(AM_CFLAGS)
AC_SUBST(AM_CXXFLAGS)
+# Special compiler flag hacks for various pieces of the code
AC_SUBST([FLEX_CFLAGS], $flex_cflags)
+AC_SUBST([LUAJIT_CFLAGS], $luajit_cflags)
SHARED_CFLAGS=-fPIC
SHARED_LDFLAGS=-shared
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/5fae5303/lib/Makefile.am
----------------------------------------------------------------------
diff --git a/lib/Makefile.am b/lib/Makefile.am
index fce72aa..43c0134 100644
--- a/lib/Makefile.am
+++ b/lib/Makefile.am
@@ -41,7 +41,7 @@ DIST_SUBDIRS = $(SUBDIRS)
# the -m64 flag. See configure.ac.
#
if BUILD_LUAJIT
-LUA_CFLAGS=$(CFLAGS) -DLUA_COMPAT_ALL -DLUA_USE_POSIX -DLUA_USE_DLOPEN
+LUA_CFLAGS=$(CFLAGS) $(LUAJIT_CFLAGS) -DLUA_COMPAT_ALL -DLUA_USE_POSIX -DLUA_USE_DLOPEN
all-local:
@echo "Making all in luajit"
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/5fae5303/proxy/http/HttpTransact.cc
----------------------------------------------------------------------
diff --git a/proxy/http/HttpTransact.cc b/proxy/http/HttpTransact.cc
index a738282..66b32b6 100644
--- a/proxy/http/HttpTransact.cc
+++ b/proxy/http/HttpTransact.cc
@@ -3409,7 +3409,7 @@ HttpTransact::handle_response_from_icp_suggested_host(State *s)
}
return;
}
- ink_assert(&s->hdr_info.server_request);
+ ink_assert(s->hdr_info.server_request.valid());
s->next_action = how_to_open_connection(s);
if (s->current.server == &s->server_info && s->next_hop_scheme == URL_WKSIDX_HTTP) {
HttpTransactHeaders::remove_host_name_from_url(&s->hdr_info.server_request);
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/5fae5303/proxy/logging/LogObject.cc
----------------------------------------------------------------------
diff --git a/proxy/logging/LogObject.cc b/proxy/logging/LogObject.cc
index 414d9b5..be65070 100644
--- a/proxy/logging/LogObject.cc
+++ b/proxy/logging/LogObject.cc
@@ -94,7 +94,7 @@ LogObject::LogObject(const LogFormat *format, const char *log_dir, const char *b
m_rolling_interval_sec(rolling_interval_sec), m_rolling_offset_hr(rolling_offset_hr), m_rolling_size_mb(rolling_size_mb),
m_last_roll_time(0), m_buffer_manager_idx(0)
{
- ink_assert(format != NULL);
+ ink_release_assert(format);
m_format = new LogFormat(*format);
m_buffer_manager = new LogBufferManager[m_flush_threads];
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/5fae5303/proxy/logging/LogObject.h
----------------------------------------------------------------------
diff --git a/proxy/logging/LogObject.h b/proxy/logging/LogObject.h
index a615657..649ad4f 100644
--- a/proxy/logging/LogObject.h
+++ b/proxy/logging/LogObject.h
@@ -102,7 +102,7 @@ public:
LogObject(const LogFormat *format, const char *log_dir, const char *basename, LogFileFormat file_format, const char *header,
Log::RollingEnabledValues rolling_enabled, int flush_threads, int rolling_interval_sec = 0, int rolling_offset_hr = 0,
- int rolling_size_mb = 0, bool auto_created = false) TS_NONNULL(2 /* format is required */);
+ int rolling_size_mb = 0, bool auto_created = false);
LogObject(LogObject &);
virtual ~LogObject();
[2/2] trafficserver git commit: Add TS-3516
Posted by zw...@apache.org.
Add TS-3516
Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/d0d30f8b
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/d0d30f8b
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/d0d30f8b
Branch: refs/heads/master
Commit: d0d30f8bed99500d66c0e699b3257f785a22581c
Parents: 5fae530
Author: Leif Hedstrom <zw...@apache.org>
Authored: Sun Apr 12 12:34:13 2015 -0500
Committer: Leif Hedstrom <zw...@apache.org>
Committed: Sun Apr 12 12:34:13 2015 -0500
----------------------------------------------------------------------
CHANGES | 2 ++
1 file changed, 2 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/d0d30f8b/CHANGES
----------------------------------------------------------------------
diff --git a/CHANGES b/CHANGES
index 8ca937e..336e4cb 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,8 @@
-*- coding: utf-8 -*-
Changes with Apache Traffic Server 6.0.0
+ *) [TS-3516] Fix various compile warnings with latest versions of clang.
+
*) [TS-3438]: Assert if npn protocol is invalid (empty string)
*) [TS-3501]: Support configuring socket options for client sockets