[vlc-commits] commit: Weaken test case so that it does not depend on the locale ( Rémi Denis-Courmont )

git at videolan.org git at videolan.org
Fri Oct 8 21:35:45 CEST 2010


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Fri Oct  8 22:35:18 2010 +0300| [104a9920e9b13ca005c423fbca660d12b832018e] | committer: Rémi Denis-Courmont 

Weaken test case so that it does not depend on the locale

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=104a9920e9b13ca005c423fbca660d12b832018e
---

 src/test/utf8.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/src/test/utf8.c b/src/test/utf8.c
index aa178a8..0c4425d 100644
--- a/src/test/utf8.c
+++ b/src/test/utf8.c
@@ -29,7 +29,6 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <stdbool.h>
-#include <locale.h>
 
 static void test (const char *in, const char *out)
 {
@@ -102,7 +101,6 @@ static void test_strcasestr (const char *h, const char *n, size_t offset)
 
 int main (void)
 {
-    setlocale (LC_CTYPE, "fr_FR");
     (void)setvbuf (stdout, NULL, _IONBF, 0);
     test ("", "");
 
@@ -128,8 +126,7 @@ int main (void)
     test_strcasestr ("heLLo", "la", -1);
     test_strcasestr ("heLLo", "oa", -1);
     test_strcasestr ("Télé", "é", 1);
-    test_strcasestr ("Télé", "É", 1);
-    test_strcasestr ("Télé", "Élé", 1);
+    test_strcasestr ("Télé", "élé", 1);
     test_strcasestr ("Télé", "léé", -1);
 
     return 0;



More information about the vlc-commits mailing list