summaryrefslogtreecommitdiff
path: root/converters/mimelib/files/patch-mimelib-string.cpp
blob: aad90e7a2b2e1e103d0992c5e640277f65dc83fe (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
--- mimelib/string.cpp.bak	1997-09-27 13:54:17.000000000 +0200
+++ mimelib/string.cpp	2011-01-20 11:16:24.000000000 +0100
@@ -29,7 +29,7 @@
 #include <ctype.h>
 #include <stdlib.h>
 #include <string.h>
-#include <new.h>
+#include <new>
 #include <mimelib/string.h>
 
 #define DW_MIN(a,b) ((a) <= (b) ? (a) : (b))
@@ -138,9 +138,9 @@
     assert(rep != 0);
 #if defined(DW_DEBUG_VERSION) || defined(DW_DEVELOPMENT_VERSION)
     if (rep->mRefCount <= 0) {
-        cerr << "Error: attempt to delete a DwStringRep "
+        std::cerr << "Error: attempt to delete a DwStringRep "
             "with ref count <= 0\n";
-        cerr << "(Possibly 'delete' was called twice for same object)\n";
+        std::cerr << "(Possibly 'delete' was called twice for same object)\n";
         abort();
     }
 #endif //  defined(DW_DEBUG_VERSION) || defined(DW_DEVELOPMENT_VERSION)
@@ -173,8 +173,8 @@
 {
 #if defined (DW_DEBUG_VERSION) || defined (DW_DEVELOPMENT_VERSION)
     if (mBuffer == 0) {
-        cerr << "DwStringRep destructor called for bad DwStringRep object\n";
-        cerr << "(Possibly 'delete' was called twice for same object)\n";
+        std::cerr << "DwStringRep destructor called for bad DwStringRep object\n";
+        std::cerr << "(Possibly 'delete' was called twice for same object)\n";
         abort();
     }
 #endif //  defined (DW_DEBUG_VERSION) || defined (DW_DEVELOPMENT_VERSION)
@@ -1045,7 +1045,7 @@
 }
 
 
-void DwString::WriteTo(ostream& aStrm) const
+void DwString::WriteTo(std::ostream& aStrm) const
 {
     const char* buf = mRep->mBuffer + mStart;
     for (size_t i=0; i < mLength; ++i) {
@@ -1336,7 +1336,7 @@
 }
 
 
-void DwString::PrintDebugInfo(ostream& aStrm) const
+void DwString::PrintDebugInfo(std::ostream& aStrm) const
 {
 #if defined (DW_DEBUG_VERSION)
     aStrm << 
@@ -1633,7 +1633,7 @@
 }
 
 
-ostream& operator << (ostream& aOstrm, const DwString& aStr)
+std::ostream& operator << (std::ostream& aOstrm, const DwString& aStr)
 {
     const char* buf = aStr.data();
     for (size_t i=0; i < aStr.length(); ++i) {
@@ -1643,7 +1643,7 @@
 }
 
 
-istream& getline(istream& aIstrm, DwString& aStr, char aDelim)
+std::istream& getline(std::istream& aIstrm, DwString& aStr, char aDelim)
 {
     aStr.clear();
     char ch;
@@ -1657,7 +1657,7 @@
 }
 
 
-istream& getline(istream& aIstrm, DwString& aStr)
+std::istream& getline(std::istream& aIstrm, DwString& aStr)
 {
     return getline(aIstrm, aStr, '\n');
 }