We cannot include it in an update, so just make sure it goes in the
next write cluster. This will be before an sync or fsync and
roll-forward should pick it up, so all is OK
Signed-off-by: NeilBrown <neilb@suse.de>
return err;
}
-/* FIXME I'm not logging the body of the symlink being created */
static int
lafs_symlink(struct inode *dir, struct dentry *de,
const char *symlink)
LAFSI(ino)->md.file.parent = dir->i_ino;
lafs_add_orphan(fs, inodb);
+ lafs_iolock_block(&b->b);
buf = map_dblock(b);
memcpy(buf, symlink, l);
buf[l] = 0;
set_bit(B_Valid, &b->b.flags);
lafs_dirty_dblock(b);
clear_bit(B_PinPending, &b->b.flags);
+ lafs_cluster_allocate(&b->b, 0); /* Content will go in the next cluster - almost like
+ * an update */
putdref(b, MKREF(symlink));
i_size_write(ino, l);
lafs_dirty_inode(ino);