g4tools  5.4.0
serrno
Go to the documentation of this file.
1 // Copyright (C) 2010, Guy Barrand. All rights reserved.
2 // See the file tools.license for terms.
3 
4 #ifndef tools_serrno
5 #define tools_serrno
6 
7 #include <cerrno>
8 #include <cstring>
9 #include <sstream>
10 
11 namespace tools {
12 
13 inline void serrno(std::string& a_s) {
14  std::ostringstream strm;
15  strm << (int)errno;
16  a_s = " error : ";
17  a_s += strm.str();
18  a_s += " : ";
19  a_s += strerror(errno);
20  a_s += ".";
21 }
22 
23 }
24 
25 #endif
tools::serrno
void serrno(std::string &a_s)
Definition: serrno:13
tools
inlined C code : ///////////////////////////////////
Definition: aida_ntuple:26