GNOME Bugzilla – Bug 659751
accentuated characters in filename breaks format function regexp.
Last modified: 2011-09-22 00:54:18 UTC
Created attachment 197177 [details] [review] limit the scope the format function is applied to , to avoid confusing accents with format Applying format to the full query string fails when this query srting contains spurious percent characters, ie accentuated ones. JS ERROR: !!! Exception was: Error: Unsupported conversion character %C JS ERROR: !!! lineNumber = '56' JS ERROR: !!! fileName = '"/usr/local/share/gnome-documents/js/format.js"' JS ERROR: !!! stack = '"("%C","","","C",400,"{ }FILTER ((fn:contains (fn:lower-case (tracker:coalesce(nie:title(?urn), nfo:fileName(?urn))), \"\") ||fn:contains (fn:lower-case (tracker:coalesce(nco:fullname(?creator), nco:fullname(?publisher))), \"\")) && (((fn:starts-with (nie:url(?urn), \"file:///home/prahal/Bureau\")) || (fn:starts-with (nie:url(?urn), \"file:///home/prahal/Documents\")) || (fn:starts-with (nie:url(?urn), \"file:///home/prahal/T%C3%A9l%C3%A9chargements\")) ) || ((nie:dataSource(?urn) = \"gd:goa-account:account_1316092886\") || (nie:dataSource(?urn) = \"gd:goa-account:account_1314928782\") || false)) && ((true)) && ((fn:contains(rdf:type(?urn), \"nfo#PaginatedTextDocument\") ||fn:contains(rdf:type(?urn), \"nfo#Spreadsheet\") ||fn:contains(rdf:type(?urn), \"nfo#Presentation\")))) } ORDER BY DESC (?mtime)LIMIT %d OFFSET %d")@/usr/local/share/gnome-documents/js/format.js:56 format(50,0)@/usr/local/share/gnome-documents/js/format.js:20 (true)@/usr/local/share/gnome-documents/js/query.js:152 ()@/usr/local/share/gnome-documents/js/query.js:181 ()@/usr/local/share/gnome-documents/js/trackerController.js:118 ()@/usr/local/share/gnome-documents/js/trackerController.js:127 ()@/usr/local/share/gnome-documents/js/trackerController.js:63 TrackerController()@/usr/local/share/gnome-documents/js/trackerController.js:35 ([object _private_Goa_Client],[object _private_Gio_SimpleAsyncResult])@/usr/local/share/gnome-documents/js/application.js:148 start()@/usr/local/share/gnome-documents/js/main.js:27 @<command line>:1 "'
Review of attachment 197177 [details] [review]: Looks good and safe. I will have to ask release-team for a hard code freeze break before pushing this though.
Pushed now after r-t approval.