File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -972,6 +972,7 @@ decompress_pos(char *ptr, WordEntryPos *pos)
972972 else
973973 {
974974 delta |= (v & LOWERMASK ) << i ;
975+ Assert (delta <= 0x3fff );
975976 * pos += delta ;
976977 WEP_SETWEIGHT (* pos , v >> 5 );
977978 return ptr ;
@@ -991,7 +992,7 @@ count_pos(char *ptr, int len)
991992 if (!(ptr [i ] & HIGHBIT ))
992993 count ++ ;
993994 }
994- Assert (! (ptr [i - 1 ] & HIGHBIT ));
995+ Assert ((ptr [i - 1 ] & HIGHBIT ) == 0 );
995996 return count ;
996997}
997998
@@ -2209,7 +2210,6 @@ rum_ts_join_pos(PG_FUNCTION_ARGS)
22092210 count2 = count_pos (in2 , VARSIZE_ANY_EXHDR (addInfo2 )),
22102211 countRes = 0 ;
22112212 int i1 = 0 , i2 = 0 ;
2212- int n_equals = 0 ;
22132213 Size size ;
22142214 WordEntryPos pos1 = 0 ,
22152215 pos2 = 0 ,
@@ -2243,7 +2243,6 @@ rum_ts_join_pos(PG_FUNCTION_ARGS)
22432243 else
22442244 {
22452245 pos [countRes ++ ] = pos1 ;
2246- n_equals ++ ;
22472246 i1 ++ ;
22482247 i2 ++ ;
22492248 if (i1 < count1 )
@@ -2276,7 +2275,7 @@ rum_ts_join_pos(PG_FUNCTION_ARGS)
22762275 }
22772276 }
22782277
2279- Assert (countRes == count1 + count2 - n_equals );
2278+ Assert (countRes <= count1 + count2 );
22802279
22812280 /*
22822281 * In some cases compressed positions may take more memory than
You can’t perform that action at this time.
0 commit comments