xalloc.cc File Reference
#include "squid.h"
#include "compat/xalloc.h"
#include "profiler/Profiler.h"
Include dependency graph for xalloc.cc:

Go to the source code of this file.

Functions

void * xcalloc (size_t n, size_t sz)
 
void * xmalloc (size_t sz)
 
void * xrealloc (void *s, size_t sz)
 
void free_const (const void *s_const)
 

Function Documentation

◆ free_const()

void free_const ( const void *  s)

free_const() - Same as free(3). Used for portability. Accepts pointers to dynamically allocated const data.

Define failure_notify to receive error message. otherwise perror() is used to display it.

Definition at line 169 of file xalloc.cc.

References free_const(), PROF_start, and PROF_stop.

Referenced by free_const(), and xfree().

◆ xcalloc()

void* xcalloc ( size_t  n,
size_t  sz 
)

xcalloc() - same as calloc(3). Used for portability. Never returns NULL; fatal on error.

Define failure_notify to receive error message. otherwise perror() is used to display it.

Definition at line 72 of file xalloc.cc.

References failure_notify, NULL, PROF_start, PROF_stop, sz, and xcalloc().

Referenced by _db_print(), accessLogReader(), MemPoolMalloc::allocate(), asnAddNet(), authDigestNonceEncode(), buildUrlFromHost(), cacheCreate(), cacheEntryCreate(), Comm::CallbackTableInit(), carpInit(), Ident::ClientAdd(), clientBeginRequest(), configDoConfigure(), icp_common_t::CreateMessage(), createRemovalPolicy_heap(), createRemovalPolicy_lru(), StatHist::deltaPctile(), do_open(), errorInitialize(), fileIteratorCreate(), FileMap::FileMap(), ftpListParseParts(), getsymbol(), FileMap::grow(), Fs::Ufs::UFSSwapDir::HandleCleanEvent(), hash_create(), hashFreeItems(), heap_walkInit(), html_quote(), idnsAddPathComponent(), SharedMemory::init(), CacheDigest::init(), fde::Init(), StatHist::init(), ipc_thread_1(), ipc_thread_2(), LoadSecurityDll(), logfile_mod_daemon_open(), logfile_mod_stdio_open(), logfile_mod_udp_open(), logfileNewBuffer(), lru_purgeInit(), lru_walkInit(), main(), memAllocBuf(), memAllocString(), MemChunk::MemChunk(), netdbDump(), netdbPeerAdd(), netdbPurgeLRU(), netdbReloadState(), new_heap(), StatHist::operator=(), parse_access_log(), parse_hostdomaintype(), parse_IpAddress_list(), parse_sslproxy_cert_adapt(), parse_sslproxy_cert_sign(), ConnStateData::parseHttpRequest(), peerSourceHashInit(), peerUserHashInit(), prepareAcceleratedURL(), ConnStateData::prepareTlsSwitchingURL(), prepareTransparentURL(), PutEnvironment(), Format::QuoteMimeBlob(), read_passwd_file(), read_request(), Mem::Report(), rfc1035MessageUnpack(), rfc1738_do_escape(), Comm::SelectLoopInit(), snmpHandleUdp(), squidaio_shutdown(), StatHist::StatHist(), storeRebuildStart(), swapStateReader(), urnParseReply(), wccp2_add_service_list(), wccp2AssignBuckets(), wccp2HandleUdp(), wccp2Init(), Fs::Ufs::UFSSwapDir::writeCleanStart(), xcalloc(), and xprof_average().

◆ xmalloc()

void* xmalloc ( size_t  sz)

xmalloc() - same as malloc(3). Used for portability. Never returns NULL; fatal on error.

Define failure_notify to receive error message. otherwise perror() is used to display it.

Definition at line 106 of file xalloc.cc.

References failure_notify, NULL, PROF_start, PROF_stop, sz, and xmalloc().

Referenced by xmalloc().

◆ xrealloc()

void* xrealloc ( void *  s,
size_t  sz 
)

xrealloc() - same as realloc(3). Used for portability. Never returns NULL; fatal on error.

Definition at line 137 of file xalloc.cc.

References failure_notify, NULL, PROF_start, PROF_stop, sz, and xrealloc().

Referenced by _heap_grow(), add_User_Group(), cbdataInternalInitType(), memReallocBuf(), parseOneConfigFile(), snmpAddNodeChild(), snmpCreateOidFromStr(), storeReplAdd(), WIN32_build_argv(), and xrealloc().

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors