##// END OF EJS Templates
parsers: fix refcount bug on corrupt index...
Matt Mackall -
r16597:b767382a stable
parent child Browse files
Show More
@@ -983,6 +983,7 b' static int index_init(indexObject *self,'
983 self->ntdepth = self->ntsplits = 0;
983 self->ntdepth = self->ntsplits = 0;
984 self->ntlookups = self->ntmisses = 0;
984 self->ntlookups = self->ntmisses = 0;
985 self->ntrev = -1;
985 self->ntrev = -1;
986 Py_INCREF(self->data);
986
987
987 if (self->inlined) {
988 if (self->inlined) {
988 long len = inline_scan(self, NULL);
989 long len = inline_scan(self, NULL);
@@ -998,7 +999,6 b' static int index_init(indexObject *self,'
998 self->raw_length = size / 64;
999 self->raw_length = size / 64;
999 self->length = self->raw_length + 1;
1000 self->length = self->raw_length + 1;
1000 }
1001 }
1001 Py_INCREF(self->data);
1002
1002
1003 return 0;
1003 return 0;
1004 bail:
1004 bail:
General Comments 0
You need to be logged in to leave comments. Login now