return false;
}
-static int ext4_iterate_ea(struct ext4_xattr_ref *ref,
- struct ext4_xattr_item *item)
-{
- int i;
- ext4_dprintf(EXT4_DEBUG_INODE, "item->name: ");
- for (i = 0;i < item->name_len;i++)
- ext4_dprintf(EXT4_DEBUG_INODE, "%c", item->name[i]);
-
- ext4_dprintf(EXT4_DEBUG_INODE, "\n");
-
- return EXT4_XATTR_ITERATE_CONT;
-}
-
/*
* NOTICE: if filetype is equal to EXT4_DIRENTRY_UNKNOWN,
* any filetype of the target dir entry will be accepted.
if (f->flags & O_APPEND)
f->fpos = f->fsize;
- /* FIXME: Debugging code on EA. */
- {
- int private_ret;
- struct ext4_xattr_ref xattr_ref;
- private_ret = ext4_fs_get_xattr_ref(&f->mp->fs, &ref,
- &xattr_ref);
- if (private_ret == EOK) {
-#define EXT4_XATTR_TEST_DATA_SIZE 20
-#define EXT4_XATTR_TEST_NAME "bad_boy"
- static char test_data[EXT4_XATTR_TEST_DATA_SIZE] = {'a'};
- ext4_dmask_set(EXT4_DEBUG_ALL);
- ext4_fs_set_xattr(&xattr_ref,
- EXT4_XATTR_INDEX_USER,
- EXT4_XATTR_TEST_NAME,
- strlen(EXT4_XATTR_TEST_NAME),
- test_data,
- EXT4_XATTR_TEST_DATA_SIZE,
- 0);
- ext4_fs_xattr_iterate(&xattr_ref,
- ext4_iterate_ea);
- ext4_fs_put_xattr_ref(&xattr_ref);
- }
- }
}
r = ext4_fs_put_inode_ref(&ref);