Misc file clean

上级 d9af5f78
......@@ -9,12 +9,12 @@
u64 namehash(const strbuf<DIRSIZ>&);
struct file : public referenced {
static file *alloc();
file *dup();
int stat(struct stat*);
int read(char *addr, int n);
ssize_t pread(char *addr, size_t n, off_t offset);
int write(char *addr, int n);
static file* alloc();
file* dup();
int stat(struct stat*);
int read(char *addr, int n);
ssize_t pread(char *addr, size_t n, off_t offset);
int write(char *addr, int n);
enum { FD_NONE, FD_PIPE, FD_INODE, FD_SOCKET } type;
......@@ -25,10 +25,12 @@ struct file : public referenced {
struct pipe *pipe;
struct inode *ip;
u32 off;
NEW_DELETE_OPS(file);
private:
file();
file();
file& operator=(const file&);
file(const file& x);
NEW_DELETE_OPS(file);
protected:
virtual void onzero() const;
......
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论