Fix diagnostics on filter template
Diagnostics can be required on both instance and session level, so both cases need to be handled explicitly. In addition, some reinterpret_casts were changed into static_casts. Reinterpret_cast needs to be used with the instance, which is a void** but static_cast is sufficient for the session, which is void*.
This commit is contained in:
6
server/modules/filter/cache/cachefilter.cc
vendored
6
server/modules/filter/cache/cachefilter.cc
vendored
@ -223,6 +223,12 @@ CacheFilterSession* CacheFilter::newSession(SESSION* pSession)
|
||||
return CacheFilterSession::Create(m_sCache.get(), pSession);
|
||||
}
|
||||
|
||||
// static
|
||||
void CacheFilter::diagnostics(DCB* pDcb)
|
||||
{
|
||||
m_sCache->show(pDcb);
|
||||
}
|
||||
|
||||
// static
|
||||
uint64_t CacheFilter::getCapabilities()
|
||||
{
|
||||
|
2
server/modules/filter/cache/cachefilter.hh
vendored
2
server/modules/filter/cache/cachefilter.hh
vendored
@ -29,6 +29,8 @@ public:
|
||||
|
||||
CacheFilterSession* newSession(SESSION* pSession);
|
||||
|
||||
void diagnostics(DCB* pDcb);
|
||||
|
||||
static uint64_t getCapabilities();
|
||||
|
||||
private:
|
||||
|
Reference in New Issue
Block a user