summaryrefslogtreecommitdiff
blob: 0464d47dad080c918fde0f38c3dd573448e10dc5 (plain)
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
diff --git a/plugins/IMs/jianpin/dict/char2db.cpp b/plugins/IMs/jianpin/dict/char2db.cpp
index d881f20..e4ddbab 100644
--- a/plugins/IMs/jianpin/dict/char2db.cpp
+++ b/plugins/IMs/jianpin/dict/char2db.cpp
@@ -74,11 +74,7 @@ void build_freq_tab(char * filename)
 {
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	f.open(filename, ios_base::in);
-#else
-	f.open(filename, "r");
-#endif
 	istream in(&f);
 
 	char cbuf[10];
@@ -154,11 +150,7 @@ int main(int argc, char * argv[])
 
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	f.open(argv[1], ios_base::in);
-#else
-	f.open(argv[1], "r");
-#endif
 	istream in(&f);
 
 	char mark;
diff --git a/plugins/IMs/jianpin/dict/word2db.cpp b/plugins/IMs/jianpin/dict/word2db.cpp
index 806f6c4..5baa630 100644
--- a/plugins/IMs/jianpin/dict/word2db.cpp
+++ b/plugins/IMs/jianpin/dict/word2db.cpp
@@ -83,11 +83,7 @@ int main(int argc, char * argv[])
 
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	f.open(argv[1], ios_base::in);
-#else
-	f.open(argv[1], "r");
-#endif
 	istream in(&f);
 
 	char mark;
diff --git a/plugins/IMs/table/dict/word2db.cpp b/plugins/IMs/table/dict/word2db.cpp
index 17d0dcf..275ee61 100644
--- a/plugins/IMs/table/dict/word2db.cpp
+++ b/plugins/IMs/table/dict/word2db.cpp
@@ -90,11 +90,7 @@ int main(int argc, char * argv[])
 
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	f.open(argv[1], ios_base::in);
-#else
-	f.open(argv[1], "r");
-#endif
 	istream in(&f);
 
 	char mark;
diff --git a/plugins/IMs/wubi/dict/word2db.cpp b/plugins/IMs/wubi/dict/word2db.cpp
index 0dbc7e4..e191aa8 100644
--- a/plugins/IMs/wubi/dict/word2db.cpp
+++ b/plugins/IMs/wubi/dict/word2db.cpp
@@ -81,11 +81,7 @@ int main(int argc, char * argv[])
 
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	f.open(argv[1], ios_base::in);
-#else
-	f.open(argv[1], "r");
-#endif
 	istream in(&f);
 
 	char mark;
diff --git a/xsim/conf.cpp b/xsim/conf.cpp
index a073bb2..a2bffb0 100644
--- a/xsim/conf.cpp
+++ b/xsim/conf.cpp
@@ -133,11 +133,7 @@ int TConf::init()
         filebuf f;
 
 	char dummy[MAX_PATH_LEN + 1];
-#ifdef _CPP_BITS_IOSBASE_H
 	if (!f.open(config_path.tombs(dummy, MAX_PATH_LEN), ios_base::in)){
-#else
-	if (!f.open(config_path.tombs(dummy, MAX_PATH_LEN), "r")){
-#endif
 		cerr << "XSIM: failed opening config file" << endl;
 		return 1;
 		}
@@ -340,11 +336,7 @@ void TConf::save_config(const wchar_t * configname, vector<TWstring> & name, vec
 
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	if (f.open(path.tombs(dummy, MAX_PATH_LEN), ios_base::out)){
-#else
-	if (f.open(path.tombs(dummy, MAX_PATH_LEN), "w")){
-#endif
 		ostream out(&f);
 		for (size_t i = 0; i < name.size(); i++){
 			out << name[i].tombs(dummy, MAX_PATH_LEN) << '\t';
@@ -372,11 +364,7 @@ int TConf::load_config(const wchar_t * configname, vector<TWstring> & name, vect
 
         filebuf f;
 
-#ifdef _CPP_BITS_IOSBASE_H
 	if (f.open(path.tombs(dummy, MAX_PATH_LEN), ios_base::in)){
-#else
-	if (f.open(path.tombs(dummy, MAX_PATH_LEN), "r")){
-#endif
 		istream in(&f);
 		char n[MAX_PATH_LEN + 1];
 		char v[MAX_PATH_LEN + 1];