rpms/alexandria/devel alexandria-0.6.3-library-utf8-string.patch, 1.3, 1.4

Mamoru Tasaka mtasaka at fedoraproject.org
Thu Feb 26 02:07:45 UTC 2009


Author: mtasaka

Update of /cvs/extras/rpms/alexandria/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv14381

Modified Files:
	alexandria-0.6.3-library-utf8-string.patch 
Log Message:
Oops...

alexandria-0.6.3-library-utf8-string.patch:

Index: alexandria-0.6.3-library-utf8-string.patch
===================================================================
RCS file: /cvs/extras/rpms/alexandria/devel/alexandria-0.6.3-library-utf8-string.patch,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- alexandria-0.6.3-library-utf8-string.patch	26 Feb 2009 01:54:16 -0000	1.3
+++ alexandria-0.6.3-library-utf8-string.patch	26 Feb 2009 02:07:14 -0000	1.4
@@ -1,14 +1,13 @@
 Index: lib/alexandria/ui/sidepane.rb
 ===================================================================
---- lib/alexandria/ui/sidepane.rb	(revision 1013)
+--- lib/alexandria/ui/sidepane.rb	(revision 1012)
 +++ lib/alexandria/ui/sidepane.rb	(working copy)
-@@ -19,21 +19,39 @@
+@@ -19,18 +19,39 @@
          x and x.name != @parent.selected_library.name
        end
  
 -      def contains_illegal_character new_text
--        /(\/)/.match(new_text) 
--        # only forbid / character (since Library names become dir names)
+-        /([^\w\s'"()&?!:;.\-])/.match(new_text)
 +      # if new_text is invalid utf-8, returns true
 +      # if new_text contains disallowed char (/), returns a MatchData object
 +      # otherwise returns nil
@@ -22,7 +21,7 @@
 +          log.warn { "New library name not valid UTF-8: #{ex.message}" }
 +          return true
 +        end
-         # /([^\w\s'"()&?!:;.\-])/.match(new_text) # anglocentric!
++        # /([^\w\s'"()&?!:;.\-])/.match(new_text) # anglocentric!
        end
  
        def on_edited_library cell, path_string, new_text
@@ -33,7 +32,6 @@
          if cell.text != new_text
            if match = contains_illegal_character(new_text)
 -            log.debug { "Illegal character" }
--            puts match
 -            ErrorDialog.new(@main_app, _("Invalid library name '%s'") % new_text,
 -              _("The name provided contains the " + "illegal character '<i>%s</i>'.") %
 -            match[1].gsub(/&/, "&amp;"))




More information about the scm-commits mailing list