Changeset 15457 for trunk/FACT++


Ignore:
Timestamp:
04/30/13 10:14:31 (11 years ago)
Author:
tbretz
Message:
Make java.his go to the same path as other 'log'-files
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/Readline.cc

    r15075 r15457  
    6767#include "tools.h"
    6868#include "Time.h"
     69
     70namespace fs = boost::filesystem;
    6971
    7072using namespace std;
     
    12701272void Readline::StaticPushHistory(const string &fname="")
    12711273{
     1274    fs::path his = fs::path(This->fName).parent_path();
     1275    his /= fname;
     1276
    12721277    write_history(This->fName.c_str());
    12731278    stifle_history(0);
    12741279    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
    12761285}
    12771286
     
    12861295void Readline::StaticPopHistory(const string &fname="")
    12871296{
    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
    12901308    stifle_history(0);
    12911309    unstifle_history();
Note: See TracChangeset for help on using the changeset viewer.