* Sebastian Hammer, Adam Dickmeiss
*
* $Log: physical.c,v $
- * Revision 1.7 1995-12-06 14:48:27 quinn
+ * Revision 1.9 1996-02-06 10:19:57 quinn
+ * Attempt at fixing bug. Not all blocks were read before they were unlinked
+ * prior to a remap operation.
+ *
+ * Revision 1.8 1996/01/29 09:47:11 quinn
+ * Fixed mean little bug in the read-table code.
+ *
+ * Revision 1.7 1995/12/06 14:48:27 quinn
* Fixed some strange bugs.
*
* Revision 1.6 1995/09/04 12:33:47 adam
is_mbuf *buf;
assert(block->state == IS_MBSTATE_UNREAD);
- block->data = buf = xmalloc_mbuf(IS_MBUF_TYPE_LARGE);
+ block->data = buf = xmalloc_mbuf(IS_MBUF_TYPE_LARGE);
toread = tab->is->types[tab->pos_type].blocksize;
if (toread > is_mbuf_size[buf->type])
{
block->state = IS_MBSTATE_CLEAN;
}
else
- block->bread = buf->num * is_keysize(tab->is);
+ block->bread = buf->offset + buf->num * is_keysize(tab->is);
return 0;
}
{
memcpy(type->dbuf + sum, b->data + b->offset, v = b->num *
is_keysize(tab->is));
+
sum += v;
assert(sum <= type->blocksize);
}
is_mblock *p;
for (p = tab->data; p; p = p->next)
+ {
if (p->diskpos >= 0)
{
is_freestore_free(tab->is, tab->pos_type, p->diskpos);
p->diskpos = -1;
}
+ }
}
static is_mbuf *mbuf_takehead(is_mbuf **mb, int *num, int keysize)