ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/repos/HostStatus/HostStatus.hpp
(Generate patch)

Comparing HostStatus/HostStatus.hpp (file contents):
Revision 32 by Douglas Thrift, 2003-11-14T23:44:08-08:00 vs.
Revision 34 by Douglas Thrift, 2003-11-15T01:06:43-08:00

# Line 12 | Line 12
12   #include <iostream>
13   #include <string>
14   #include <sstream>
15 + #include <list>
16   #include <map>
17   #include <cstdlib>
18   #include <ctime>
# Line 28 | Line 29 | inline string sgetenv(const string& name
29          return value != NULL ? value : "";
30   }
31  
32 < inline int sputenv(const string& name) { return putenv(name.c_str()); }
32 > inline int sputenv(const string& name)
33 > {
34 >        char* value = new char[name.size() + 1];
35 >
36 >        sprintf(value, name.c_str());
37 >        
38 >        int code = putenv(value);
39 >
40 >        return code;
41 > }
42 >
43   inline void sunsetenv(const string& name) { unsetenv(name.c_str()); }
44  
45   class HostStatus
# Line 39 | Line 50 | private:
50          Format format;
51          void parse(const string& method);
52          void display(const string& method);
53 +        void header() {}
54 +        void footer() {}
55   public:
56          HostStatus();
57          ~HostStatus() {}

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines