Created
September 13, 2008 17:18
-
-
Save kovyrin/10622 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- constraints_parser.c (revision 59) | |
+++ constraints_parser.c (working copy) | |
@@ -230,8 +230,9 @@ | |
len = offs += field->fixed_length; | |
} | |
resolved: | |
+ offs &= 0xffff; | |
if (rec + offs - page > UNIV_PAGE_SIZE) { | |
- if (debug) printf("Invalid offset for field %li: %li\n", i, offs); | |
+ if (debug) printf("Invalid offset for field %lu: %lu\n", i, offs); | |
return FALSE; | |
} | |
rec_offs_base(offsets)[i + 1] = len; | |
@@ -264,8 +265,9 @@ | |
offs |= REC_OFFS_SQL_NULL; | |
} | |
+ offs &= 0xffff; | |
if (rec + offs - page > UNIV_PAGE_SIZE) { | |
- if (debug) printf("Invalid offset for field %li: %li\n", i, offs); | |
+ if (debug) printf("Invalid offset for field %lu: %lu\n", i, offs); | |
return FALSE; | |
} | |
@@ -287,8 +289,9 @@ | |
offs |= REC_OFFS_EXTERNAL; | |
} | |
+ offs &= 0xffff; | |
if (rec + offs - page > UNIV_PAGE_SIZE) { | |
- if (debug) printf("Invalid offset for field %li: %li\n", i, offs); | |
+ if (debug) printf("Invalid offset for field %lu: %lu\n", i, offs); | |
return FALSE; | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment