]> andersk Git - moira.git/commitdiff
fix for queries with LIKE clause at the end of the qualifier
authordanw <danw>
Wed, 1 Apr 1998 03:04:21 +0000 (03:04 +0000)
committerdanw <danw>
Wed, 1 Apr 1998 03:04:21 +0000 (03:04 +0000)
server/qrtn.pc

index 35249c87f11f25faee4195da701c67a979c11230..303bdc8f1c8d393830d8ad27e8f3de9e17cb4590 100644 (file)
@@ -501,11 +501,11 @@ char *build_qual(char *fmt_buf, int argc, char *argv[])
            }
 
          /* if no pattern characters, write over "LIKE" with " =  " */
-         if (!pattern)
+         if (!pattern && !escape)
            memcpy(likepos, " =  ", 4);
 
          fmt = arg + 2;
-         while (*fmt != ' ')
+         while (*fmt && *fmt != ' ')
            *res++ = *fmt++;
 
          if (escape)
This page took 0.042927 seconds and 5 git commands to generate.