add dfs_fd check code in dfs and fix a warning.

git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2547 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
goprife@gmail.com
2012-12-29 06:28:28 +00:00
parent c0fadff061
commit 58fc3334b0
2 changed files with 12 additions and 2 deletions
+3 -1
View File
@@ -282,10 +282,12 @@ struct dirent
#endif
/* file descriptor */
#define DFS_FD_MAGIC 0xfdfd
struct dfs_fd
{
rt_uint16_t magic; /* file descriptor magic number */
rt_uint16_t type; /* Type (regular or socket) */
char *path; /* Name (below mount point) */
int type; /* Type (regular or socket) */
int ref_count; /* Descriptor reference count */
struct dfs_filesystem *fs; /* Resident file system */