diff options
author | fluxgen <fluxgen> | 2002-01-08 11:36:43 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2002-01-08 11:36:43 (GMT) |
commit | 49f3715f0cfcdce8fe67e71157ab1efffb920586 (patch) | |
tree | 2a4ce45bb6375777ac6e5b45759ff12c2e12c38b | |
parent | 2528b513ff69e9e7f5948f4647b39a216cdd3dac (diff) | |
download | fluxbox_paul-49f3715f0cfcdce8fe67e71157ab1efffb920586.zip fluxbox_paul-49f3715f0cfcdce8fe67e71157ab1efffb920586.tar.bz2 |
Fixed getRcFilename
-rw-r--r-- | src/fluxbox.cc | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/fluxbox.cc b/src/fluxbox.cc index 6369212..8f8e044 100644 --- a/src/fluxbox.cc +++ b/src/fluxbox.cc | |||
@@ -1693,15 +1693,19 @@ void Fluxbox::save_rc(void) { | |||
1693 | 1693 | ||
1694 | //-------- getRcFilename ------------- | 1694 | //-------- getRcFilename ------------- |
1695 | // Returns filename of resource file | 1695 | // Returns filename of resource file |
1696 | // TODO: possible replacement with strstream? | ||
1696 | //------------------------------------ | 1697 | //------------------------------------ |
1697 | char *Fluxbox::getRcFilename() { | 1698 | char *Fluxbox::getRcFilename() { |
1698 | char *dbfile=0; | 1699 | char *dbfile=0; |
1699 | 1700 | ||
1700 | if (!rc_file) { | 1701 | if (!rc_file) { |
1701 | strstream str; | ||
1702 | str<<getenv("HOME")<<"/."<<RC_PATH<<"/"<<RC_INIT_FILE; | ||
1703 | 1702 | ||
1704 | return StringUtil::strdup(str.str()); | 1703 | string str(getenv("HOME")+string("/.")+RC_PATH+string("/")+RC_INIT_FILE); |
1704 | #ifdef DEBUG | ||
1705 | cerr<<__FILE__<<"("<<__LINE__<<"): str.size()="<<str.size()<<endl; | ||
1706 | cerr<<__FILE__<<"("<<__LINE__<<"): str="<<str<<endl; | ||
1707 | #endif | ||
1708 | return StringUtil::strdup(str.c_str()); | ||
1705 | } else | 1709 | } else |
1706 | dbfile = StringUtil::strdup(rc_file); | 1710 | dbfile = StringUtil::strdup(rc_file); |
1707 | 1711 | ||