1
0
mirror of https://github.com/fumiama/fumidb.git synced 2026-06-11 05:30:26 +08:00

finish int16 index

This commit is contained in:
源文雨
2022-05-03 13:38:50 +08:00
parent 34700361c2
commit 05f6c7a3c4
2 changed files with 32 additions and 15 deletions

View File

@@ -149,6 +149,24 @@ int main() {
}
}
for(int i = 57000; i < 65536+259; i++) {
if(insert_item(fd, TYPE_INT16, index, (key_t)i, i*1234)) {
printf("%u ", (uint16_t)i);
fflush(stdout);
perror("insert_int16_item");
return 10;
}
}
for(int i = 57000; i < 65536+259; i++) {
if((int)find_item_by_key(fd, TYPE_INT16, index, (key_t)i) != i*1234) {
printf("%u ", (uint16_t)i);
fflush(stdout);
perror("find_item_by_key");
return 11;
}
}
close(fd);
/* end test int16 */
// remove("types_test_tmp.bin");