diff options
author | joerg <joerg@pkgsrc.org> | 2013-03-02 18:20:19 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2013-03-02 18:20:19 +0000 |
commit | d4caee9091ee21fb1e7954b3f355c6b2b2108fa0 (patch) | |
tree | b2cdd2ffd2dc97f469fc2e09a9f0a453f8822f5b /chat/centerim/patches | |
parent | 638ed7caa04426e3e1e38b2cc55d924e7fe382cc (diff) | |
download | pkgsrc-d4caee9091ee21fb1e7954b3f355c6b2b2108fa0.tar.gz |
Be a friend of the class, not of every member. Use the class we are
friend with to find the method we are interested in, not the evil
parent. Consistently return a value from a non-void function.
Diffstat (limited to 'chat/centerim/patches')
-rw-r--r-- | chat/centerim/patches/patch-libjabber_jconn.c | 40 | ||||
-rw-r--r-- | chat/centerim/patches/patch-src_hooks_msnhook.cc | 22 | ||||
-rw-r--r-- | chat/centerim/patches/patch-src_hooks_msnhook.h | 49 |
3 files changed, 111 insertions, 0 deletions
diff --git a/chat/centerim/patches/patch-libjabber_jconn.c b/chat/centerim/patches/patch-libjabber_jconn.c new file mode 100644 index 00000000000..f3759a8e8bf --- /dev/null +++ b/chat/centerim/patches/patch-libjabber_jconn.c @@ -0,0 +1,40 @@ +$NetBSD: patch-libjabber_jconn.c,v 1.1 2013/03/02 18:20:19 joerg Exp $ + +--- libjabber/jconn.c.orig 2013-03-01 12:39:48.000000000 +0000 ++++ libjabber/jconn.c +@@ -824,7 +824,7 @@ void *jabber_recieve_file_fd(void *arg) + free(hash); + close(sock); + close(fd_file); +- return; ++ return NULL; + } + + recv( sock, buff, SEND_BUF, 0 ); +@@ -833,7 +833,7 @@ void *jabber_recieve_file_fd(void *arg) + free(hash); + close(sock); + close(fd_file); +- return; ++ return NULL; + } + + //socks5 bytestream packet +@@ -851,7 +851,7 @@ void *jabber_recieve_file_fd(void *arg) + free(hash); + close(sock); + close(fd_file); +- return; ++ return NULL; + } + recv( sock, buff, 47, 0 ); + if( buff[0] != 0x05 || buff[3] != 0x03 ) +@@ -859,7 +859,7 @@ void *jabber_recieve_file_fd(void *arg) + free(hash); + close(sock); + close(fd_file); +- return; ++ return NULL; + } + + diff --git a/chat/centerim/patches/patch-src_hooks_msnhook.cc b/chat/centerim/patches/patch-src_hooks_msnhook.cc new file mode 100644 index 00000000000..078da27b7e1 --- /dev/null +++ b/chat/centerim/patches/patch-src_hooks_msnhook.cc @@ -0,0 +1,22 @@ +$NetBSD: patch-src_hooks_msnhook.cc,v 1.1 2013/03/02 18:20:19 joerg Exp $ + +--- src/hooks/msnhook.cc.orig 2013-03-01 12:43:38.000000000 +0000 ++++ src/hooks/msnhook.cc +@@ -684,7 +684,7 @@ void msncallbacks::gotBuddyListInfo(MSN: + + mhook.setautostatus(mhook.manualstatus); + mhook.timer_ping = timer_current; +- mhook.log(abstracthook::logLogged); ++ mhook.log(msnhook::logLogged); + face.update(); + } + +@@ -883,7 +883,7 @@ void msncallbacks::closingConnection(MSN + clist.setoffline(msn); + + mhook.fonline = false; +- mhook.log(abstracthook::logDisconnected); ++ mhook.log(msnhook::logDisconnected); + + face.update(); + } diff --git a/chat/centerim/patches/patch-src_hooks_msnhook.h b/chat/centerim/patches/patch-src_hooks_msnhook.h new file mode 100644 index 00000000000..351a46193cd --- /dev/null +++ b/chat/centerim/patches/patch-src_hooks_msnhook.h @@ -0,0 +1,49 @@ +$NetBSD: patch-src_hooks_msnhook.h,v 1.1 2013/03/02 18:20:19 joerg Exp $ + +--- src/hooks/msnhook.h.orig 2009-08-27 11:16:41.000000000 +0000 ++++ src/hooks/msnhook.h +@@ -61,43 +61,7 @@ class msncallbacks : public MSN::Callbac + }; + + class msnhook : public abstracthook { +- +- friend void msncallbacks::registerSocket(int s, int reading, int writing); +- friend void msncallbacks::unregisterSocket(int s); +- friend void msncallbacks::showError(MSN::Connection * conn, string msg); +- friend void msncallbacks::buddyChangedStatus(MSN::Connection * conn, MSN::Passport buddy, string friendlyname, MSN::BuddyStatus state); +- friend void msncallbacks::buddyOffline(MSN::Connection * conn, MSN::Passport buddy); +- friend void msncallbacks::log(int writing, const char* buf); +- friend void msncallbacks::gotFriendlyName(MSN::Connection * conn, string friendlyname); +- friend void msncallbacks::gotBuddyListInfo(MSN::NotificationServerConnection * conn, MSN::ListSyncInfo * data); +- friend void msncallbacks::gotLatestListSerial(MSN::Connection * conn, int serial); +- friend void msncallbacks::gotGTC(MSN::Connection * conn, char c); +- friend void msncallbacks::gotBLP(MSN::Connection * conn, char c); +- friend void msncallbacks::gotNewReverseListEntry(MSN::Connection * conn, MSN::Passport buddy, std::string friendlyname); +- friend void msncallbacks::addedListEntry(MSN::Connection * conn, std::string list, MSN::Passport buddy, int groupID); +- friend void msncallbacks::removedListEntry(MSN::Connection * conn, std::string list, MSN::Passport buddy, int groupID); +- friend void msncallbacks::addedGroup(MSN::Connection * conn, string groupName, int groupID); +- friend void msncallbacks::removedGroup(MSN::Connection * conn, int groupID); +- friend void msncallbacks::renamedGroup(MSN::Connection * conn, int groupID, string newGroupName); +- friend void msncallbacks::gotSwitchboard(MSN::SwitchboardServerConnection * conn, const void * tag); +- friend void msncallbacks::buddyJoinedConversation(MSN::SwitchboardServerConnection * conn, MSN::Passport buddy, std::string friendlyname, int is_initial); +- friend void msncallbacks::buddyLeftConversation(MSN::SwitchboardServerConnection * conn, MSN::Passport buddy); +- friend void msncallbacks::gotInstantMessage(MSN::SwitchboardServerConnection * conn, MSN::Passport buddy, std::string friendlyname, MSN::Message * msg); +- friend void msncallbacks::failedSendingMessage(MSN::Connection * conn); +- friend void msncallbacks::buddyTyping(MSN::Connection * conn, MSN::Passport buddy, std::string friendlyname); +- friend void msncallbacks::gotInitialEmailNotification(MSN::Connection * conn, int unread_inbox, int unread_folders); +- friend void msncallbacks::gotNewEmailNotification(MSN::Connection * conn, string from, string subject); +- friend void msncallbacks::gotFileTransferInvitation(MSN::Connection * conn, MSN::Passport buddy, std::string friendlyname, MSN::FileTransferInvitation * inv); +- friend void msncallbacks::fileTransferProgress(MSN::FileTransferInvitation * inv, string status, unsigned long recv, unsigned long total); +- friend void msncallbacks::fileTransferFailed(MSN::FileTransferInvitation * inv, int error, string message); +- friend void msncallbacks::fileTransferSucceeded(MSN::FileTransferInvitation * inv); +- friend void msncallbacks::gotNewConnection(MSN::Connection * conn); +- friend void msncallbacks::closingConnection(MSN::Connection * conn); +- friend void msncallbacks::changedStatus(MSN::Connection * conn, MSN::BuddyStatus state); +- friend int msncallbacks::connectToServer(string server, int port, bool *connected); +- friend int msncallbacks::listenOnPort(int port); +- friend string msncallbacks::getOurIP(); +- friend string msncallbacks::getSecureHTTPProxy(); ++ friend class msncallbacks; + + protected: + imstatus ourstatus; |