#include <klibc/string.h>
-#include <sys/dirent_defs.h>
+#include <usr/lunaix/dirent_defs.h>
extern struct cake_pile* drec_cache_pile;
u32_t l = drec->name.len;
while (l < (u32_t)-1 && drec->name.content[l--] != ';')
;
+
l = (l + 1) ? l : drec->name.len;
l = MIN(l, ISO9660_IDLEN - 1);
- strncpy(cache->name_val, drec->name.content, l);
+ strncpy(cache->name_val, (const char*)drec->name.content, l);
+
cache->name = HSTR(cache->name_val, l);
hstr_rehash(&cache->name, HSTR_FULL_HASH);
}
int
iso9660_setup_dnode(struct v_dnode* dnode, struct v_inode* inode)
{
- if (!(inode->itype & VFS_IFDIR)) {
+ if ((inode->itype & F_FILE)) {
vfs_assign_inode(dnode, inode);
return 0;
}
do {
if (blk_offset >= ISO9660_BLKSZ - sizeof(struct iso_drecord)) {
current_pos += ISO9660_BLKSZ;
- errno = dev->read(dev, records, blk + current_pos, ISO9660_BLKSZ);
+ errno =
+ dev->ops.read(dev, records, blk + current_pos, ISO9660_BLKSZ);
if (errno < 0) {
errno = EIO;
goto done;