@@ -583,9 +583,6 @@ static OsBcacheBlock *AllocNewBlock(OsBcache *bc, BOOL read, UINT64 num)
|
||||
|
||||
if (prefer->used) {
|
||||
MergeSyncBlocks(bc, prefer);
|
||||
}
|
||||
|
||||
if (prefer->used) {
|
||||
BcacheSyncBlock(bc, prefer);
|
||||
DelBlock(bc, prefer);
|
||||
}
|
||||
|
||||
@@ -160,7 +160,7 @@ typedef int VfsHashCmp(struct Vnode *vnode, void *arg);
|
||||
|
||||
int VnodesInit(void);
|
||||
int VnodeDevInit(void);
|
||||
int VnodeAlloc(struct VnodeOps *vop, struct Vnode **vnode);
|
||||
int VnodeAlloc(struct VnodeOps *vop, struct Vnode **newVnode);
|
||||
int VnodeFree(struct Vnode *vnode);
|
||||
int VnodeLookup(const char *path, struct Vnode **vnode, uint32_t flags);
|
||||
int VnodeLookupFullpath(const char *fullpath, struct Vnode **vnode, uint32_t flags);
|
||||
|
||||
@@ -761,11 +761,6 @@ static int os_shell_cmd_do_rmdir(const char *pathname)
|
||||
}
|
||||
if (strcmp(dirent->d_name, "..") && strcmp(dirent->d_name, ".")) {
|
||||
size_t fullpath_buf_size = strlen(pathname) + strlen(dirent->d_name) + SEPARATOR_EOF_LEN;
|
||||
if (fullpath_buf_size <= 0) {
|
||||
PRINTK("buffer size is invalid!\n");
|
||||
(void)closedir(d);
|
||||
return -1;
|
||||
}
|
||||
fullpath = (char *)malloc(fullpath_buf_size);
|
||||
if (fullpath == NULL) {
|
||||
PRINTK("malloc failure!\n");
|
||||
|
||||
@@ -260,7 +260,7 @@ int VnodeDrop(void)
|
||||
static char *NextName(char *pos, uint8_t *len)
|
||||
{
|
||||
char *name = NULL;
|
||||
while (*pos != 0 && *pos == '/') {
|
||||
while (*pos == '/') {
|
||||
pos++;
|
||||
}
|
||||
if (*pos == '\0') {
|
||||
|
||||
Reference in New Issue
Block a user