Changeset 15457
- Timestamp:
- 04/30/13 10:14:31 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/Readline.cc
r15075 r15457 67 67 #include "tools.h" 68 68 #include "Time.h" 69 70 namespace fs = boost::filesystem; 69 71 70 72 using namespace std; … … 1270 1272 void Readline::StaticPushHistory(const string &fname="") 1271 1273 { 1274 fs::path his = fs::path(This->fName).parent_path(); 1275 his /= fname; 1276 1272 1277 write_history(This->fName.c_str()); 1273 1278 stifle_history(0); 1274 1279 unstifle_history(); 1275 read_history(fname.c_str()); 1280 #if BOOST_VERSION < 104600 1281 read_history(his.c_str()); 1282 #else 1283 read_history(his.string().c_str()); 1284 #endif 1276 1285 } 1277 1286 … … 1286 1295 void Readline::StaticPopHistory(const string &fname="") 1287 1296 { 1288 write_history(fname.c_str()); 1289 history_truncate_file(fname.c_str(), 1000); 1297 fs::path his = fs::path(This->fName).parent_path(); 1298 his /= fname; 1299 1300 #if BOOST_VERSION < 104600 1301 write_history(his.c_str()); 1302 history_truncate_file(his.c_str(), 1000); 1303 #else 1304 write_history(his.string().c_str()); 1305 history_truncate_file(his.string().c_str(), 1000); 1306 #endif 1307 1290 1308 stifle_history(0); 1291 1309 unstifle_history();
Note:
See TracChangeset
for help on using the changeset viewer.