virtual struct dirent *readdir() { if (xffind("*", &info)!=0) { return NULL; } memcpy(cur_entry.d_name, info.name, sizeof(info.name)); return &cur_entry; }
virtual int read(struct dirent *ent) { lock(); if (xffind("*", &info)!=0) { unlock(); return 0; } memcpy(ent->d_name, info.name, sizeof(info.name)); unlock(); return 1; }