diff -Nru bmdc-0.0.3/dcpp/ClientManager.h bmdc-0.0.3/dcpp/ClientManager.h --- bmdc-0.0.3/dcpp/ClientManager.h 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/dcpp/ClientManager.h 2014-01-26 16:35:41.000000000 +0000 @@ -136,15 +136,14 @@ return true; } - int getMode(const string& aHubUrl) const; bool isActive(const string& aHubUrl = Util::emptyString) const; - //TODO ? IPv6 ( may done :p) + //TODO: ? IPv6 ( may done :p) void setIpAddress(const UserPtr& p, const string& ip); void sendAction(OnlineUser& ou, const int aAction); void sendRawCommand(OnlineUser& user, const string& aRaw, bool checkProtection = false); - //TODO ? suite for FakeChecker ? + //TODO: ? suite for FakeChecker ? void addCheckToQueue(const HintedUser hintedUser, bool filelist); void checkCheating(const HintedUser& p, DirectoryListing* dl); diff -Nru bmdc-0.0.3/dcpp/HubEntry.h bmdc-0.0.3/dcpp/HubEntry.h --- bmdc-0.0.3/dcpp/HubEntry.h 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/dcpp/HubEntry.h 2014-01-26 16:35:41.000000000 +0000 @@ -73,7 +73,7 @@ FavoriteHubEntry(const HubEntry& rhs) : name(rhs.getName()), server(rhs.getServer()), hubDescription(rhs.getDescription()), encoding(Text::systemCharset), autoConnect(false), showUserList(true), - tabText(Util::emptyString) , tabIconStr(Util::emptyString) , notify(false) + tabText(Util::emptyString) , tabIconStr(Util::emptyString) , notify(true) { } FavoriteHubEntry(const FavoriteHubEntry& rhs) : diff -Nru bmdc-0.0.3/dcpp/Util.cpp bmdc-0.0.3/dcpp/Util.cpp --- bmdc-0.0.3/dcpp/Util.cpp 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/dcpp/Util.cpp 2014-01-26 16:35:41.000000000 +0000 @@ -46,13 +46,11 @@ string Util::emptyString; wstring Util::emptyStringW; tstring Util::emptyStringT; - bool Util::away = false; bool Util::manualAway = false; string Util::awayMsg; time_t Util::awayTime; uint64_t Util::uptime = 0; - string Util::paths[Util::PATH_LAST]; bool Util::localMode = true; @@ -485,20 +483,11 @@ return ret; } -/* -string Util::getAwayMessage() { - return (formatTime(awayMsg.empty() ? SETTING(DEFAULT_AWAY_MESSAGE) : awayMsg, awayTime)) + " <" APPNAME " v" VERSIONSTRING ">"; -}*/ string Util::getAwayMessage(ParamMap& params) { - //time_t currentTime; - //time(¤tTime); - //int currentHour = localtime(¤tTime)->tm_hour; - params["idleTI"] = Text::fromT(formatSeconds(time(NULL) - awayTime)); params["time"] = Util::toString(awayTime); return formatParams((awayMsg.empty() ? SETTING(DEFAULT_AWAY_MESSAGE) : awayMsg), params); - } string Util::formatBytes(int64_t aBytes) { @@ -553,7 +542,7 @@ #endif } -string Util::getLocalIp() { +string Util::getLocalIp() {//@TODO:IPv6? const auto& bindAddr = CONNSETTING(BIND_ADDRESS); if(!bindAddr.empty() && bindAddr != SettingsManager::getInstance()->getDefault(SettingsManager::BIND_ADDRESS)) { return bindAddr; diff -Nru bmdc-0.0.3/dcpp/Util.h bmdc-0.0.3/dcpp/Util.h --- bmdc-0.0.3/dcpp/Util.h 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/dcpp/Util.h 2014-01-26 16:35:41.000000000 +0000 @@ -260,7 +260,6 @@ return ((size + blockSize - 1) / blockSize) * blockSize; } - static int64_t toInt64(const string& aString) { #ifdef _WIN32 return _atoi64(aString.c_str()); diff -Nru bmdc-0.0.3/debian/bzr-builder.manifest bmdc-0.0.3/debian/bzr-builder.manifest --- bmdc-0.0.3/debian/bzr-builder.manifest 2014-01-16 19:46:52.000000000 +0000 +++ bmdc-0.0.3/debian/bzr-builder.manifest 2014-01-26 16:35:42.000000000 +0000 @@ -1,2 +1,2 @@ -# bzr-builder format 0.3 deb-version {debupstream}-0ubuntu0~343 -lp:bmdc++ revid:mank1@seznam.cz-20140116184711-b7714sna8qo3oz4j +# bzr-builder format 0.3 deb-version {debupstream}-0ubuntu0~347 +lp:bmdc++ revid:mank1@seznam.cz-20140126152934-fbwyidaidtc8oe5y diff -Nru bmdc-0.0.3/debian/changelog bmdc-0.0.3/debian/changelog --- bmdc-0.0.3/debian/changelog 2014-01-16 19:46:52.000000000 +0000 +++ bmdc-0.0.3/debian/changelog 2014-01-26 16:35:42.000000000 +0000 @@ -1,8 +1,8 @@ -bmdc (0.0.3-0ubuntu0~343~ubuntu13.04.1) raring; urgency=low +bmdc (0.0.3-0ubuntu0~347~ubuntu13.04.1) raring; urgency=low * Auto build. - -- Mank Thu, 16 Jan 2014 19:46:52 +0000 + -- Mank Sun, 26 Jan 2014 16:35:42 +0000 bmdc (0.0.3-201~natty) natty; urgency=low Binary files /tmp/IWHYP3cSYu/bmdc-0.0.3/icons/hicolor/16x16/status/bmdc-zerozeroone-pasive.png and /tmp/REUXfx644j/bmdc-0.0.3/icons/hicolor/16x16/status/bmdc-zerozeroone-pasive.png differ diff -Nru bmdc-0.0.3/linux/WulforUtil.cc bmdc-0.0.3/linux/WulforUtil.cc --- bmdc-0.0.3/linux/WulforUtil.cc 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/linux/WulforUtil.cc 2014-01-26 16:35:41.000000000 +0000 @@ -761,8 +761,10 @@ gchar *path = g_strdup_printf(_DATADIR PATH_SEPARATOR_STR "bmdc/country/%s.png", (gchar *)country.c_str()); GdkPixbuf *pixbuf = gdk_pixbuf_new_from_file_at_size(path,15,15,&error); - if (error != NULL || pixbuf == NULL) + if (error != NULL || pixbuf == NULL) { g_warning("[BMDC::Country] Cannot open image: %s => %s", path, error->message); + g_error_free(error); + } g_free(path); countryIcon.insert(make_pair(country,pixbuf)); return pixbuf; @@ -771,7 +773,7 @@ string WulforUtil::StringToUpper(std::string myString) { const int length = myString.length(); - if(myString.empty()) + if(length == 0) return Util::emptyString; for(int i=0; i != length; ++i) { @@ -782,9 +784,9 @@ string WulforUtil::getCountryCode(string _countryname) { - std::transform(_countryname.begin(), _countryname.end(), _countryname.begin(), (int(*)(int))toupper); if(_countryname.empty()) return Util::emptyString; + std::transform(_countryname.begin(), _countryname.end(), _countryname.begin(), (int(*)(int))toupper); for(uint8_t q = 0; q < (sizeof(CountryNames) / sizeof(CountryNames[0])); ++q) { @@ -947,14 +949,14 @@ /**/ int dettotal = SETTING(DETECTIONS); int detfail = SETTING(DETECTIONF); - string build = "Builded with "; + string build = "Built with "; #ifdef __clang__ build += "clang " __clang_version__; #elif defined(__GNUC__) build += "gcc " __VERSION__; #endif message = "\n-= Stats " + dcpp::fullVersionString - +"\n " +build+" =-\n" + +"\n-= " +build+" =-\n" + "-= " + rel + " " + mach + " =-\n" + "-= Uptime: " + Util::formatSeconds(Util::getUptime()) + " =-\n" + "-= Sys Uptime: " + Util::toString(udays) + " days," + Util::toString(uhour) + " Hours," + Util::toString(umin) + " min. =-\n" @@ -967,7 +969,7 @@ status += _("Specify a search string"); else openURI("http://www.google.com/search?q=" + param); - }else if ( cmd == "imdb"){ + }else if ( cmd == "imdb") { if(param.empty()) status += _("Specify a search string"); else diff -Nru bmdc-0.0.3/linux/emoticonsdialog.cc bmdc-0.0.3/linux/emoticonsdialog.cc --- bmdc-0.0.3/linux/emoticonsdialog.cc 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/linux/emoticonsdialog.cc 2014-01-26 16:35:41.000000000 +0000 @@ -44,10 +44,6 @@ packName(packName), address(address) { -#if !GTK_CHECK_VERSION(2, 12, 0) - tooltips = gtk_tooltips_new(); - g_object_ref_sink(tooltips); -#endif g_object_ref_sink(Menu); if(!address.empty()) { Emoticons *em = Emoticons::start(packName,false); @@ -67,9 +63,6 @@ EmoticonsDialog::~EmoticonsDialog() { -#if !GTK_CHECK_VERSION(2, 12, 0) - g_object_unref(tooltips); -#endif g_object_unref(Menu); map::iterator it; if( (it = hubs.find(address)) != hubs.end() ) @@ -302,11 +295,8 @@ gtk_widget_show(icon); gtk_grid_attach(GTK_GRID(table), icon, left_attach, top_attach, 1, 1); -#if GTK_CHECK_VERSION(2, 12, 0) gtk_widget_set_tooltip_text(icon, name); -#else - gtk_tooltips_set_tip(tooltips, icon, name, NULL); -#endif + g_object_set_data_full(G_OBJECT(icon), "text", g_strdup(name), g_free); g_signal_connect(G_OBJECT(icon), "clicked", G_CALLBACK(onChat), (gpointer) this); diff -Nru bmdc-0.0.3/linux/emoticonsdialog.hh bmdc-0.0.3/linux/emoticonsdialog.hh --- bmdc-0.0.3/linux/emoticonsdialog.hh 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/linux/emoticonsdialog.hh 2014-01-26 16:35:41.000000000 +0000 @@ -45,9 +45,6 @@ GtkWidget *Menu; // packs menu GtkWidget *dialog; // emoticons dialog -#if !GTK_CHECK_VERSION(2, 12, 0) - GtkTooltips *tooltips; // tooltips for all icon widgets -#endif int icon_width; int icon_height; std::string currIconSize; diff -Nru bmdc-0.0.3/linux/hub.cc bmdc-0.0.3/linux/hub.cc --- bmdc-0.0.3/linux/hub.cc 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/linux/hub.cc 2014-01-26 16:35:41.000000000 +0000 @@ -1630,9 +1630,10 @@ if (newTag != NULL) { // Cursor is entering a tag. - gchar *tmp; + gchar *tmp = NULL; g_object_get(G_OBJECT(newTag),"name",&tmp,NULL); selectedTagStr = string(tmp); + g_free(tmp); if (find(TagsMap, TagsMap + Tag::TAG_MYNICK, newTag) == TagsMap + Tag::TAG_MYNICK) { @@ -2068,6 +2069,7 @@ gchar *tmp = NULL; g_object_get(G_OBJECT(tag), "name", &tmp, NULL); string tagName = string(tmp); + g_free(tmp); hub->nickToChat_gui(tagName.substr(tagPrefix.size())); @@ -2079,6 +2081,7 @@ gchar *tmp = NULL; g_object_get(G_OBJECT(tag), "name", &tmp, NULL); string tagName = string(tmp); + g_free(tmp); if (hub->findNick_gui(tagName.substr(tagPrefix.size()), &nickIter)) @@ -2149,6 +2152,7 @@ gchar *tmp = NULL; g_object_get(G_OBJECT(tag),"name",&tmp,NULL); hub->ip = string(tmp); + g_free(tmp); if(event->type == GDK_BUTTON_PRESS) { @@ -4663,8 +4667,8 @@ //custom popup menu GtkWidget *Hub::createmenu() { - GtkWidget *item = getFItem(); - gtk_menu_item_set_label(GTK_MENU_ITEM(item),address.c_str()); + //GtkWidget *item = getFItem(); + gtk_menu_item_set_label(GTK_MENU_ITEM(/*item*/getFItem()),address.c_str()); userCommandMenu1->cleanMenu_gui(); userCommandMenu1->addUser(client->getMyIdentity().getUser()->getCID().toBase32()); diff -Nru bmdc-0.0.3/linux/privatemessage.cc bmdc-0.0.3/linux/privatemessage.cc --- bmdc-0.0.3/linux/privatemessage.cc 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/linux/privatemessage.cc 2014-01-26 16:35:41.000000000 +0000 @@ -950,9 +950,10 @@ if (newTag != NULL) { // Cursor is entering a tag. - gchar *tmp; + gchar *tmp = NULL; g_object_get(G_OBJECT(newTag),"name",&tmp,NULL); selectedTagStr = string(tmp); + g_free(tmp); if (find(TagsMap, TagsMap + Tag::TAG_URL, newTag) == TagsMap + Tag::TAG_URL) { @@ -1144,9 +1145,10 @@ if (event->type == GDK_BUTTON_PRESS) { - gchar *tmp; + gchar *tmp = NULL; g_object_get(G_OBJECT(tag),"name",&tmp,NULL); pm->selectedTagStr = string(tmp); + g_free(tmp); switch (event->button.button) { @@ -1170,9 +1172,10 @@ if (event->type == GDK_BUTTON_PRESS) { - gchar *tmp; + gchar *tmp = NULL; g_object_get(G_OBJECT(tag),"name",&tmp,NULL); pm->selectedTagStr = string(tmp); + g_free(tmp); switch (event->button.button) { @@ -1196,9 +1199,10 @@ if (event->type == GDK_BUTTON_PRESS) { - gchar *tmp; + gchar *tmp = NULL; g_object_get(G_OBJECT(tag),"name",&tmp,NULL); pm->selectedTagStr = string(tmp); + g_free(tmp); switch (event->button.button) { @@ -1220,9 +1224,10 @@ gboolean PrivateMessage::onIpTagEvent_gui(GtkTextTag *tag, GObject *textView, GdkEvent *event , GtkTextIter *iter, gpointer data) { PrivateMessage *pm = (PrivateMessage *)data; - gchar *tmp; + gchar *tmp = NULL; g_object_get(G_OBJECT(tag),"name",&tmp,NULL); pm->ip = std::string(tmp); + g_free(tmp); if(event->type == GDK_BUTTON_PRESS) { @@ -1534,7 +1539,7 @@ return; if(logPath.empty()) return; - //.. + StringList lines; try { const int MAX_SIZE = 32 * 1024; @@ -1562,8 +1567,8 @@ GtkWidget *PrivateMessage::createmenu() { string nicks = WulforUtil::getNicks(this->cid, this->hubUrl); - GtkWidget *item = getFItem(); - gtk_menu_item_set_label(GTK_MENU_ITEM(item), nicks.c_str()); +// GtkWidget *item = getFItem(); + gtk_menu_item_set_label(GTK_MENU_ITEM(/*item*/getFItem()), nicks.c_str()); userCommandMenu->cleanMenu_gui(); userCommandMenu->addUser(cid); diff -Nru bmdc-0.0.3/linux/settingsmanager.cc bmdc-0.0.3/linux/settingsmanager.cc --- bmdc-0.0.3/linux/settingsmanager.cc 2014-01-16 19:46:50.000000000 +0000 +++ bmdc-0.0.3/linux/settingsmanager.cc 2014-01-26 16:35:41.000000000 +0000 @@ -373,7 +373,7 @@ defaultString.insert(StringMap::value_type("userlist-bg-protected", "#BFBFBF")); defaultString.insert(StringMap::value_type("userlist-bg-ignored", "#BFBFBF")); /**/ - defaultString.insert(StringMap::value_type("custom-aliases", "")); + defaultString.insert(StringMap::value_type("custom-aliases", "#")); /* Extended text color*/ defaultString.insert(StringMap::value_type("text-cheat-fore-color", "red")); defaultString.insert(StringMap::value_type("text-cheat-back-color", "white"));