stub_cbdata.cc
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2017 The Squid Software Foundation and contributors
3  *
4  * Squid software is distributed under GPLv2+ license and includes
5  * contributions from numerous individuals and organizations.
6  * Please see the COPYING and CONTRIBUTORS files for details.
7  */
8 
9 #include "squid.h"
10 #include "cbdata.h"
11 
12 #define STUB_API "cbdata.cc"
13 #include "tests/STUB.h"
14 
16 void *cbdataInternalAlloc(cbdata_type, const char *, int sz) {
17  return xcalloc(1, sz);
18 }
19 void *cbdataInternalFree(void *p, const char *, int) {
20  xfree(p);
21  return nullptr;
22 }
23 #if USE_CBDATA_DEBUG
24 void cbdataInternalLockDbg(const void *, const char *, int) STUB
25 void cbdataInternalUnlockDbg(const void *, const char *, int) STUB
26 int cbdataInternalReferenceDoneValidDbg(void **, void **, const char *, int) STUB_RETVAL(0)
27 #else
28 void cbdataInternalLock(const void *) STUB
29 void cbdataInternalUnlock(const void *) STUB
30 int cbdataInternalReferenceDoneValid(void **, void **) STUB_RETVAL(0)
31 #endif
32 
33 int cbdataReferenceValid(const void *) STUB_RETVAL(0)
34 cbdata_type cbdataInternalAddType(cbdata_type, const char *, int) STUB_RETVAL(CBDATA_UNKNOWN)
35 
void cbdataRegisterWithCacheManager(void) STUB void *cbdataInternalAlloc(cbdata_type
Definition: cbdata.cc:210
char * p
Definition: membanger.c:43
void const char int sz return xcalloc(1, sz)
cbdata_type cbdataInternalAddType(cbdata_type type, const char *name, int size)
Definition: cbdata.cc:197
void cbdataInternalUnlock(const void *p)
Definition: cbdata.cc:365
void void ** STUB_RETVAL(0) int cbdataReferenceValid(const void *) STUB_RETVAL(0) cbdata_type cbdataInternalAddType(cbdata_type
Definition: stub_liblog.cc:90
int cbdataInternalReferenceDoneValid(void **pp, void **tp)
Definition: cbdata.cc:438
#define STUB
macro to stub a void function.
Definition: STUB.h:33
void * cbdataInternalFree(void *p, const char *, int)
Definition: stub_cbdata.cc:19
void * cbdataInternalAlloc(cbdata_type type, const char *file, int line)
Definition: cbdata.cc:224
void cbdataInternalLock(const void *) STUB void cbdataInternalUnlock(const void *) STUB int cbdataInternalReferenceDoneValid(void **
int cbdataReferenceValid(const void *p)
Definition: cbdata.cc:412
#define xfree
static const cbdata_type CBDATA_UNKNOWN
Definition: cbdata.h:196

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors