ATLAS Offline Software
Loading...
Searching...
No Matches
Control
AthAllocators
src
Control/AthAllocators/src/exceptions.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3
*/
10
11
#include "
AthAllocators/exceptions.h
"
12
#include <sstream>
13
#include <string.h>
14
15
16
namespace
SG
{
17
18
19
//*************************************************************************
20
21
25
ExcDifferentArenas::ExcDifferentArenas
()
26
:
std
::
runtime_error
(
"SG::ExcDifferentAreas: Attempt to assign between ArenaSharedHeapSTLAllocators for different arenas."
)
27
{
28
}
29
30
31
//*************************************************************************
32
33
34
std::string
excProtection_format
(
int
errnum)
35
{
36
std::ostringstream os;
37
os <<
"SG::ExcProtection: Attempt to change memory protection failed: "
;
38
char
errbuf[256];
39
#ifdef _GNU_SOURCE
40
os << strerror_r (errnum, errbuf,
sizeof
(errbuf));
41
#else
42
strerror_r (errnum, errbuf,
sizeof
(errbuf));
43
os << errbuf;
44
#endif
45
return
os.str();
46
}
47
48
53
ExcProtection::ExcProtection
(
int
errnum)
54
:
std
::
runtime_error
(
excProtection_format
(errnum))
55
{
56
}
57
58
59
//*************************************************************************
60
61
65
ExcProtected::ExcProtected
()
66
:
std
::
runtime_error
(
"SG::ExcProtected: Attempt to change protected arena."
)
67
{
68
}
69
70
71
}
// namespace SG
exceptions.h
Exceptions that can be thrown from AthAllocators.
SG::ExcDifferentArenas::ExcDifferentArenas
ExcDifferentArenas()
Constructor.
Definition
Control/AthAllocators/src/exceptions.cxx:25
SG::ExcProtected::ExcProtected
ExcProtected()
Constructor.
Definition
Control/AthAllocators/src/exceptions.cxx:65
SG::ExcProtection::ExcProtection
ExcProtection(int errnum)
Constructor.
Definition
Control/AthAllocators/src/exceptions.cxx:53
runtime_error
STL class.
SG
Forward declaration.
Definition
CaloCellPacker_400_500.h:32
SG::excProtection_format
std::string excProtection_format(int errnum)
Definition
Control/AthAllocators/src/exceptions.cxx:34
std
STL namespace.
Generated on
for ATLAS Offline Software by
1.14.0