rpms/freetalk/devel freetalk-3.2-glibc210.patch, NONE, 1.1 freetalk.spec, 1.4, 1.5

Debarshi Ray rishi at fedoraproject.org
Fri Feb 27 19:20:26 UTC 2009


Author: rishi

Update of /cvs/pkgs/rpms/freetalk/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv14002

Modified Files:
	freetalk.spec 
Added Files:
	freetalk-3.2-glibc210.patch 
Log Message:
* Wed Feb 25 2009 Debarshi Ray <rishi at fedoraproject.org> - 3.2-3
- Fixed build failure with glibc-2.10.


freetalk-3.2-glibc210.patch:

--- NEW FILE freetalk-3.2-glibc210.patch ---
diff -urNp freetalk-3.2.orig/src/callbacks.cc freetalk-3.2/src/callbacks.cc
--- freetalk-3.2.orig/src/callbacks.cc	2009-02-25 01:31:29.826691032 +0530
+++ freetalk-3.2/src/callbacks.cc	2009-02-25 02:56:04.323962193 +0530
@@ -1,7 +1,7 @@
 /*
   callbacks.c: Callback functions
   
-  Copyright (c) 2005, 2006, 2007 Freetalk Core Team
+  Copyright (c) 2005, 2006, 2007, 2009 Freetalk Core Team
   This file is part of GNU Freetalk.
   
   Freetalk is free software; you can redistribute it and/or modify
@@ -20,6 +20,7 @@
 */
 
 #include <stdio.h>
+#include <string>
 #include <string.h>
 #include <stdlib.h>
 #include <glib.h> 
@@ -116,8 +117,9 @@ ft_msg_msg_handler (LmMessageHandler *ha
 		    LmMessage *msg, gpointer user_data)
 {
   LmMessageNode *root, *body, *x;
-  const char *from, *msg_str, *type;
+  const char *msg_str, *type;
   char *ts = NULL;
+  std::string from;
 
   root = lm_message_get_node (msg);
   body = lm_message_node_get_child (root, "body");
@@ -152,11 +154,12 @@ ft_msg_msg_handler (LmMessageHandler *ha
     set_hook_return (0);
     /* TBD : make the below stripping of /Resource configurable */
     if (1) {
-      if (strchr (from, '/'))
-	*strchr (from, '/') = '\0';
+      const size_t pos = from.find("/");
+      if (pos != std::string::npos)
+	from.replace(pos, from.size() - pos, "");
     }
     {
-      FtRosterItem *item = ft_roster_lookup (from);
+      FtRosterItem *item = ft_roster_lookup (from.c_str());
       char *nickname;
       
       if (!item)
@@ -166,17 +169,17 @@ ft_msg_msg_handler (LmMessageHandler *ha
       
       scm_run_hook (ex_message_receive_hook,
 		    scm_list_n (ts ? scm_from_locale_string (ts) : scm_from_locale_string (""),
-				scm_from_locale_string (from),
+				scm_from_locale_string (from.c_str()),
 				nickname ? scm_from_locale_string (nickname) : scm_from_locale_string (""),
 				scm_from_locale_string (msg_str),
 				SCM_UNDEFINED));
     }
     if (ts) g_free (ts);
     
-    if (get_hook_return () == 1)
+    if (get_hook_return () == 1) 
       return LM_HANDLER_RESULT_REMOVE_MESSAGE;
     
-    PRINTF ("%s: %s", from, msg_str);
+    PRINTF ("%s: %s", from.c_str(), msg_str);
   } else {
     /* This logic should be looked into : FIXME */
     ft_send_file_message_data (msg);


Index: freetalk.spec
===================================================================
RCS file: /cvs/pkgs/rpms/freetalk/devel/freetalk.spec,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- freetalk.spec	24 Feb 2009 18:27:10 -0000	1.4
+++ freetalk.spec	27 Feb 2009 19:19:55 -0000	1.5
@@ -1,12 +1,14 @@
 Summary:	A console based Jabber client
 Name:		freetalk
 Version:	3.2
-Release:	2%{?dist}
+Release:	3%{?dist}
 License:	GPLv3+
 Group:		Applications/Internet
 URL:		http://www.gnu.org/software/freetalk/
 Source0:	http://sv.gnu.org/download/freetalk/%{name}-%{version}.tar.gz
 
+Patch0:		%{name}-%{version}-glibc210.patch
+
 BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 
 Requires:	words
@@ -25,6 +27,7 @@
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %configure --disable-rpath
@@ -75,14 +78,17 @@
 %{_datadir}/%{name}/extensions
 
 %changelog
-* Tue Feb 24 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 3.2-2
-- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
+* Wed Feb 25 2009 Debarshi Ray <rishi at fedoraproject.org> - 3.2-3
+- Fixed build failure with glibc-2.10.
+
+* Tue Feb 24 2009 Release Engineering <rel-eng at fedoraproject.org> - 3.2-2
+- Autorebuild for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
 
 * Fri Nov 21 2008 Matej Cepl <mcepl at redhat.com> 3.2-1
-- Update to the new upstream release.
+- Version bump to 3.2.
 
 * Wed Sep 03 2008 Debarshi Ray <rishi at fedoraproject.org> - 3.1-1
-- Version bump to 0.32.
+- Version bump to 3.1.
 - open(2) problem fixed by upstream.
 
 * Thu Feb 14 2008 Debarshi Ray <rishi at fedoraproject.org> - 3.0-2




More information about the fedora-extras-commits mailing list