Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(554)

Side by Side Diff: third_party/libxml/src/testAutomata.c

Issue 1193533007: Upgrade to libxml 2.9.2 and libxslt 1.1.28 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: no iconv Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/libxml/src/schematron.c ('k') | third_party/libxml/src/testC14N.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * testRegexp.c: simple module for testing regular expressions 2 * testRegexp.c: simple module for testing regular expressions
3 * 3 *
4 * See Copyright for the status of this software. 4 * See Copyright for the status of this software.
5 * 5 *
6 * Daniel Veillard <veillard@redhat.com> 6 * Daniel Veillard <veillard@redhat.com>
7 */ 7 */
8 8
9 #include "libxml.h" 9 #include "libxml.h"
10 #ifdef LIBXML_AUTOMATA_ENABLED 10 #ifdef LIBXML_AUTOMATA_ENABLED
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 fclose(input); 63 fclose(input);
64 return; 64 return;
65 } 65 }
66 ret = 0; 66 ret = 0;
67 67
68 while (fgets(expr, 4500, input) != NULL) { 68 while (fgets(expr, 4500, input) != NULL) {
69 if (expr[0] == '#') 69 if (expr[0] == '#')
70 continue; 70 continue;
71 len = strlen(expr); 71 len = strlen(expr);
72 len--; 72 len--;
73 » while ((len >= 0) && 73 » while ((len >= 0) &&
74 ((expr[len] == '\n') || (expr[len] == '\t') || 74 ((expr[len] == '\n') || (expr[len] == '\t') ||
75 (expr[len] == '\r') || (expr[len] == ' '))) len--; 75 (expr[len] == '\r') || (expr[len] == ' '))) len--;
76 » expr[len + 1] = 0; 76 » expr[len + 1] = 0;
77 if (len >= 0) { 77 if (len >= 0) {
78 if ((am != NULL) && (expr[0] == 't') && (expr[1] == ' ')) { 78 if ((am != NULL) && (expr[0] == 't') && (expr[1] == ' ')) {
79 char *ptr = &expr[2]; 79 char *ptr = &expr[2];
80 int from, to; 80 int from, to;
81 81
82 from = scanNumber(&ptr); 82 from = scanNumber(&ptr);
83 if (*ptr != ' ') { 83 if (*ptr != ' ') {
84 xmlGenericError(xmlGenericErrorContext, 84 xmlGenericError(xmlGenericErrorContext,
85 "Bad line %s\n", expr); 85 "Bad line %s\n", expr);
86 break; 86 break;
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 return(0); 300 return(0);
301 } 301 }
302 302
303 #else 303 #else
304 #include <stdio.h> 304 #include <stdio.h>
305 int main(int argc ATTRIBUTE_UNUSED, char **argv ATTRIBUTE_UNUSED) { 305 int main(int argc ATTRIBUTE_UNUSED, char **argv ATTRIBUTE_UNUSED) {
306 printf("%s : Automata support not compiled in\n", argv[0]); 306 printf("%s : Automata support not compiled in\n", argv[0]);
307 return(0); 307 return(0);
308 } 308 }
309 #endif /* LIBXML_AUTOMATA_ENABLED */ 309 #endif /* LIBXML_AUTOMATA_ENABLED */
OLDNEW
« no previous file with comments | « third_party/libxml/src/schematron.c ('k') | third_party/libxml/src/testC14N.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698