Read and convert base64-encode marc
[yaz-moved-to-github.git] / test / test_libstemmer.c
index 3c18e04..0d18c7b 100644 (file)
@@ -1,5 +1,5 @@
 /* This file is part of the YAZ toolkit.
- * Copyright (C) 1995-2011 Index Data
+ * Copyright (C) 1995-2012 Index Data
  * See the file LICENSE for details.
  */
 #if HAVE_CONFIG_H
@@ -20,13 +20,12 @@ int test_stemmer_stem(yaz_stemmer_p stemmer, const char* to_stem, const char *ex
     struct icu_buf_utf16 *src  = icu_buf_utf16_create(0);
     struct icu_buf_utf16 *dst  = icu_buf_utf16_create(0);
     struct icu_buf_utf8  *dst8 = icu_buf_utf8_create(0);
-
+    int rc = 0;
     UErrorCode status; 
     const char *result;
+
     icu_utf16_from_utf8_cstr(src, to_stem, &status);
     yaz_stemmer_stem(stemmer, dst, src, &status); 
-    /* Assume fail */
-    int rc = 0;
     if (status == U_ZERO_ERROR) {
         icu_utf16_to_utf8(dst8, dst, &status);
         result = icu_buf_utf8_to_cstr(dst8);