Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/yaz
[yaz-moved-to-github.git] / src / cclqfile.c
index 7583610..246b832 100644 (file)
@@ -6,6 +6,9 @@
  * \file cclqfile.c
  * \brief Implements parsing of CCL qualifier specs in files
  */
+#if HAVE_CONFIG_H
+#include <config.h>
+#endif
 
 #include <stdio.h>
 #include <stdlib.h>
@@ -83,10 +86,11 @@ int ccl_qual_field2(CCL_bibset bibset, const char *cp, const char *qual_name,
 
             qlist[i++] = lead_str;
 
-            while ((t=yaz_tok_move(tp)) == YAZ_TOK_STRING)
+            while (t == YAZ_TOK_STRING)
             {
                 if (i < sizeof(qlist)/sizeof(*qlist)-1)
                     qlist[i++] = xstrdup(yaz_tok_parse_string(tp));
+                t = yaz_tok_move(tp);
             }
             qlist[i] = 0;
             yaz_tok_parse_destroy(tp);