diff create.cpp @ 500:fbcc1303dfeb memory-leaks

Fixed bug in LSH_N_POINT_BITS coding when using AudioDB with LSH indexes
author mas01mc
date Sat, 10 Jan 2009 20:01:53 +0000
parents 282c651e2fbb
children
line wrap: on
line diff
--- a/create.cpp	Sat Jan 10 13:38:22 2009 +0000
+++ b/create.cpp	Sat Jan 10 20:01:53 2009 +0000
@@ -55,11 +55,11 @@
   // For backward-compatibility, Record the point-encoding parameter for LSH indexing in the adb header
   // If this value is 0 then it will be set to 14
 
-  #if LSH_N_POINT_BITS > 31
-  #error "AudioDB Compile ERROR: consistency check of O2_LSH_POINT_BITS failed (>31)"
-  #endif
+#if LSH_N_POINT_BITS > LSH_POINT_BITS_FIELD_MAX
+#error "AudioDB Compile ERROR: consistency check of O2_LSH_POINT_BITS failed (>31)"
+#endif
   
-  dbH->flags |= LSH_N_POINT_BITS << 27;
+  dbH->flags |= LSH_N_POINT_BITS << LSH_POINT_BITS_FIELD_POSITION;
 
   // If database will fit in a single file the vectors are copied into the AudioDB instance
   // Else all the vectors are left on the FileSystem and we use the dataOffset as storage