If we only have a reference to a file block but have not read it in, we
don't actually know the size. We maybe ought to have a better fix for this
later.
inode->blocks->len - 1);
if (b->type != BLUESKY_BLOCK_ZERO
- && b->data->len < BLUESKY_BLOCK_SIZE) {
+ && (b->type == BLUESKY_BLOCK_REF
+ || b->data->len < BLUESKY_BLOCK_SIZE)) {
bluesky_block_touch(inode, inode->blocks->len - 1);
gsize old_size = b->data->len;
bluesky_string_resize(b->data, BLUESKY_BLOCK_SIZE);