Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,7 @@ AS_IF([test "x${has_optimizer_flags}" = "xno"],
]
)

AS_IF([test "x$ac_cv_c_compiler_version" = "x17"], [NO_WARN_CAST_FUNCTION_TYPE_MISMATCH="-Wno-cast-function-type-mismatch"], [NO_WARN_CAST_FUNCTION_TYPE_MISMATCH=""])
AS_IF([test -n "$ac_cv_c_compiler_version" && test "$ac_cv_c_compiler_version" -ge 17 2>/dev/null], [NO_WARN_CAST_FUNCTION_TYPE_MISMATCH="-Wno-cast-function-type-mismatch"], [NO_WARN_CAST_FUNCTION_TYPE_MISMATCH=""])
AC_SUBST([NO_WARN_CAST_FUNCTION_TYPE_MISMATCH])

case $host_os_def in
Expand Down
4 changes: 2 additions & 2 deletions include/tscore/CryptoHash.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ union CryptoHash {
uint8_t u8[CRYPTO_HASH_SIZE / sizeof(uint8_t)];

/// Default constructor - init to zero.
CryptoHash() { memset(this, 0, sizeof(*this)); }
CryptoHash() { memset(static_cast<void *>(this), 0, sizeof(*this)); }
/// Copy constructor.
CryptoHash(CryptoHash const &that) = default;

Expand All @@ -53,7 +53,7 @@ union CryptoHash {
operator=(CryptoHash const &that)
{
if (this != &that) {
memcpy(this, &that, sizeof(*this));
memcpy(static_cast<void *>(this), &that, sizeof(*this));
}
return *this;
}
Expand Down
4 changes: 2 additions & 2 deletions include/tscpp/util/TextView.h
Original file line number Diff line number Diff line change
Expand Up @@ -1263,7 +1263,7 @@ namespace literals
* rather bizarre to me, but there it is. Update: this depends on the version of the compiler,
* so hopefully someday this can be removed.
*/
constexpr ts::TextView operator"" _tv(const char *s, size_t n) { return {s, n}; }
constexpr ts::TextView operator""_tv(const char *s, size_t n) { return {s, n}; }
} // namespace literals

/** Functor for STL containers that need caseless comparisons of standard string types.
Expand Down Expand Up @@ -1346,7 +1346,7 @@ template <> struct iterator_traits<ts::TextView> {
//
// I couldn't think of any better place to put this, so it's here. At least @c TextView is strongly related
// to @c std::string_view.
constexpr std::string_view operator"" _sv(const char *s, size_t n)
constexpr std::string_view operator""_sv(const char *s, size_t n)
{
return {s, n};
}
2 changes: 1 addition & 1 deletion src/traffic_server/HostStatus.cc
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ HostStatus::setHostStatus(const std::string_view name, TSHostStatus status, cons
host_stat = it->second;
} else {
host_stat = static_cast<HostStatRec *>(ats_malloc(sizeof(HostStatRec)));
bzero(host_stat, sizeof(HostStatRec));
bzero(static_cast<void *>(host_stat), sizeof(HostStatRec));
hosts_statuses.emplace(name, host_stat);
}
if (reason & Reason::ACTIVE) {
Expand Down