diff options
Diffstat (limited to 'chat/ickle/patches/patch-ab')
-rw-r--r-- | chat/ickle/patches/patch-ab | 132 |
1 files changed, 132 insertions, 0 deletions
diff --git a/chat/ickle/patches/patch-ab b/chat/ickle/patches/patch-ab new file mode 100644 index 00000000000..8d2072a1255 --- /dev/null +++ b/chat/ickle/patches/patch-ab @@ -0,0 +1,132 @@ +$NetBSD: patch-ab,v 1.1.1.1 2003/04/30 00:00:19 hubertf Exp $ +--- ickle/IckleClient.cpp.orig Fri Apr 11 22:32:26 2003 ++++ ickle/IckleClient.cpp Fri Apr 11 22:34:32 2003 +@@ -162,7 +162,7 @@ + + void IckleClient::loadContactList() { + Dir dir; +- dir.list( CONTACT_DIR + "*.user" ); ++ dir.list( CONTACT_DIR + "/*.user" ); + + Dir::iterator dirit = dir.begin(); + while( dirit != dir.end() ) { +@@ -190,7 +190,7 @@ + exit(0); + break; + case 'b': // base dir +- BASE_DIR = string(optarg) + "/"; ++ BASE_DIR = string(optarg); + break; + } + } +@@ -201,18 +201,18 @@ + if (dir == NULL) dir = getenv("PWD"); + + if (dir != NULL) { +- BASE_DIR = string(dir) + "/.ickle/"; ++ BASE_DIR = string(dir) + "/.ickle"; + } else { +- BASE_DIR = ".ickle/"; ++ BASE_DIR = ".ickle"; + } + + } + +- CONTACT_DIR = BASE_DIR + "contacts/"; +- DATA_DIR = string(PKGDATADIR) + "/"; +- TRANSLATIONS_DIR = DATA_DIR + "translations/"; +- ICONS_DIR = DATA_DIR + "icons/"; +- PID_FILENAME = BASE_DIR + "ickle.pid"; ++ CONTACT_DIR = BASE_DIR + "/contacts"; ++ DATA_DIR = string(PKGDATADIR); ++ TRANSLATIONS_DIR = DATA_DIR + "/translations"; ++ ICONS_DIR = DATA_DIR + "/icons"; ++ PID_FILENAME = BASE_DIR + "/ickle.pid"; + } + + void IckleClient::usageInstructions(const char* progname) { +@@ -232,10 +232,10 @@ + void IckleClient::loadSettings() { + // load in settings + try { +- g_settings.load(BASE_DIR + "ickle.conf"); ++ g_settings.load(BASE_DIR + "/ickle.conf"); + } catch (runtime_error& e) { + ostringstream ostr; +- ostr << "Couldn't open " << BASE_DIR << "ickle.conf, using default settings" << endl ++ ostr << "Couldn't open " << BASE_DIR << "/ickle.conf, using default settings" << endl + << "This is probably the first time you've run ickle."; + SignalLog(ICQ2000::LogEvent::WARN, ostr.str()); + } +@@ -401,7 +401,7 @@ + + if (!mkdir_BASE_DIR()) return; + +- string ickle_conf = BASE_DIR + "ickle.conf"; ++ string ickle_conf = BASE_DIR + "/ickle.conf"; + + // set umask to secure value, so that if ickle.conf doesn't exist, and is created it will be safe. + mode_t old_umask = umask(0077); +@@ -410,7 +410,7 @@ + g_settings.save(ickle_conf); + } catch(runtime_error& e) { + ostringstream ostr; +- ostr << "Couldn't save " << BASE_DIR << "ickle.conf"; ++ ostr << "Couldn't save " << BASE_DIR << "/ickle.conf"; + SignalLog(ICQ2000::LogEvent::ERROR, ostr.str()); + } + +@@ -553,7 +553,7 @@ + } + + void IckleClient::logger_file_cb(const string& msg) { +- string log_file = BASE_DIR + "messages.log"; ++ string log_file = BASE_DIR + "/messages.log"; + + // set umask to secure value, so that if ickle.conf doesn't exist, and is created it will be safe. + mode_t old_umask = umask(0077); +@@ -923,7 +923,7 @@ + if (m_settingsmap.count(c->getUIN()) > 0) return; + ostringstream ostr; + +- ostr << CONTACT_DIR << c->getUIN() << ".user"; ++ ostr << CONTACT_DIR << "/" << c->getUIN() << ".user"; + + int n = 0; + struct stat fs; +@@ -934,7 +934,7 @@ + while ( stat( filename.c_str(), &fs ) == 0 ) { + ostringstream ostr; + n++; +- ostr << CONTACT_DIR << c->getUIN() << "-" << n << ".user"; ++ ostr << CONTACT_DIR << "/" << c->getUIN() << "-" << n << ".user"; + filename = ostr.str(); + } + m_settingsmap[c->getUIN()] = filename; +@@ -965,7 +965,7 @@ + // remove history file for mobile users as well, we will not be able to correctly + // reuse this history file if the same user is added anyway + if( !c->isICQContact() ) +- unlink( string(CONTACT_DIR + m_histmap[c->getUIN()]->getFilename()).c_str() ); ++ unlink( string(CONTACT_DIR + "/" + m_histmap[c->getUIN()]->getFilename()).c_str() ); + + m_histmap.erase(c->getUIN()); + m_settingsmap.erase(c->getUIN()); +@@ -1035,7 +1035,7 @@ + + void IckleClient::saveSelfContact() + { +- saveContact( icqclient.getSelfContact(), BASE_DIR + "self.user", true ); ++ saveContact( icqclient.getSelfContact(), BASE_DIR + "/" + "self.user", true ); + } + + void IckleClient::loadContact(const string& s, bool self) +@@ -1132,7 +1132,7 @@ + void IckleClient::loadSelfContact() + { + try { +- loadContact( BASE_DIR + "self.user", true ); ++ loadContact( BASE_DIR + "/" + "self.user", true ); + } catch(runtime_error& e) { + // ignore + } |