]> arthur.barton.de Git - netatalk.git/commitdiff
Spotlight: support for OS X 10.6 clients
authorRalph Boehme <rb@sernet.de>
Mon, 11 Aug 2014 05:23:31 +0000 (07:23 +0200)
committerRalph Boehme <rb@sernet.de>
Mon, 11 Aug 2014 05:23:31 +0000 (07:23 +0200)
10.6 clients seem to use simple "=" instead of "==" in equality tests
in queries.

Signed-off-by: Ralph Boehme <rb@sernet.de>
etc/spotlight/spotlight_rawquery_lexer.c
etc/spotlight/spotlight_rawquery_lexer.l

index b13b721b74b7616373bbe560f77d5126ed5766c1..c14d4ffba5fc290232591f9406e9bb7887e257e5 100644 (file)
@@ -366,8 +366,8 @@ static void yy_fatal_error (yyconst char msg[]  );
        *yy_cp = '\0'; \
        (yy_c_buf_p) = yy_cp;
 
-#define YY_NUM_RULES 17
-#define YY_END_OF_BUFFER 18
+#define YY_NUM_RULES 18
+#define YY_END_OF_BUFFER 19
 /* This struct is not used in this scanner,
    but its presence is necessary. */
 struct yy_trans_info
@@ -377,12 +377,12 @@ struct yy_trans_info
        };
 static yyconst flex_int16_t yy_accept[57] =
     {   0,
-        0,    0,   18,   17,   16,   17,    5,   17,   17,    6,
-        7,   15,   14,   12,   17,   13,   15,   15,   15,   17,
-       17,   17,   17,   11,    0,    8,   15,    0,    0,    0,
-       10,   15,   15,   15,    9,    0,    0,    0,   15,   15,
-       15,    0,    0,   15,   15,    4,    0,   15,    3,    0,
-       15,    0,    1,    0,    2,    0
+        0,    0,   19,   18,   17,   18,    5,   18,   18,    6,
+        7,   16,   15,   13,   11,   14,   16,   16,   16,   18,
+       18,   18,   18,   12,    0,    8,   16,    0,    0,    0,
+       10,   16,   16,   16,    9,    0,    0,    0,   16,   16,
+       16,    0,    0,   16,   16,    4,    0,   16,    3,    0,
+       16,    0,    1,    0,    2,    0
     } ;
 
 static yyconst flex_int32_t yy_ec[256] =
@@ -826,40 +826,45 @@ return EQUAL;
 case 11:
 YY_RULE_SETUP
 #line 38 "spotlight_rawquery_lexer.l"
-return UNEQUAL;
+return EQUAL;
        YY_BREAK
 case 12:
 YY_RULE_SETUP
 #line 39 "spotlight_rawquery_lexer.l"
-return LT;
+return UNEQUAL;
        YY_BREAK
 case 13:
 YY_RULE_SETUP
 #line 40 "spotlight_rawquery_lexer.l"
-return GT;
+return LT;
        YY_BREAK
 case 14:
 YY_RULE_SETUP
 #line 41 "spotlight_rawquery_lexer.l"
-return COMMA;
+return GT;
        YY_BREAK
 case 15:
 YY_RULE_SETUP
 #line 42 "spotlight_rawquery_lexer.l"
-{yylval.sval = talloc_strdup(SLQ_VAR, yytext); return WORD;}
+return COMMA;
        YY_BREAK
 case 16:
-/* rule 16 can match eol */
 YY_RULE_SETUP
 #line 43 "spotlight_rawquery_lexer.l"
-/* ignore */
+{yylval.sval = talloc_strdup(SLQ_VAR, yytext); return WORD;}
        YY_BREAK
 case 17:
+/* rule 17 can match eol */
 YY_RULE_SETUP
 #line 44 "spotlight_rawquery_lexer.l"
+/* ignore */
+       YY_BREAK
+case 18:
+YY_RULE_SETUP
+#line 45 "spotlight_rawquery_lexer.l"
 ECHO;
        YY_BREAK
-#line 863 "spotlight_rawquery_lexer.c"
+#line 868 "spotlight_rawquery_lexer.c"
 case YY_STATE_EOF(INITIAL):
        yyterminate();
 
@@ -1853,7 +1858,7 @@ void yyfree (void * ptr )
 
 #define YYTABLES_NAME "yytables"
 
-#line 44 "spotlight_rawquery_lexer.l"
+#line 45 "spotlight_rawquery_lexer.l"
 
 
 
index db7f40cd82f673321d33fe2edc4a6f5f65131cce..34d7e05ff21ede74ddce2e4eb788983ccb2e6e75 100644 (file)
@@ -35,6 +35,7 @@ true                                  {yylval.bval = true; return BOOL;}
 \&\&                                  return AND;
 \|\|                                  return OR;
 \=\=                                  return EQUAL;
+\=                                    return EQUAL;
 \!\=                                  return UNEQUAL;
 \<                                    return LT;
 \>                                    return GT;