[sheepdog] [PATCH 04/10] sheepfs: fix typo
Ruoyu
liangry at ucweb.com
Tue Aug 5 09:30:25 CEST 2014
Signed-off-by: Ruoyu <liangry at ucweb.com>
---
sheepfs/http.c | 2 +-
sheepfs/shadow_file.c | 2 +-
sheepfs/sheepfs.h | 2 +-
sheepfs/volume.c | 8 ++++----
4 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/sheepfs/http.c b/sheepfs/http.c
index 0f26983..881b1cb 100644
--- a/sheepfs/http.c
+++ b/sheepfs/http.c
@@ -269,7 +269,7 @@ struct read_cache {
* thread to lock same mutex twice; and a mutex with PTHREAD_MUTEX_RECURSIVE
* could be locked twice without waiting which is not satisfied for our model;
* pthread_cond_t may lose signal......so, after all, the best choice is
- * the sandard semaphore - 'sem_t'.
+ * the standard semaphore - 'sem_t'.
*
*
*
diff --git a/sheepfs/shadow_file.c b/sheepfs/shadow_file.c
index 3c44a68..4623eac 100644
--- a/sheepfs/shadow_file.c
+++ b/sheepfs/shadow_file.c
@@ -144,7 +144,7 @@ int shadow_file_delete(const char *path)
return 0;
}
-bool shadow_file_exsit(const char *path)
+bool shadow_file_exist(const char *path)
{
char p[PATH_MAX];
diff --git a/sheepfs/sheepfs.h b/sheepfs/sheepfs.h
index 5c2998b..f277deb 100644
--- a/sheepfs/sheepfs.h
+++ b/sheepfs/sheepfs.h
@@ -53,7 +53,7 @@ int shadow_file_setxattr(const char *path, const char *name,
int shadow_file_getxattr(const char *path, const char *name,
void *value, size_t size);
int shadow_file_delete(const char *path);
-bool shadow_file_exsit(const char *path);
+bool shadow_file_exist(const char *path);
bool shadow_file_stat(const char *path, struct stat *st);
/* volume.c */
diff --git a/sheepfs/volume.c b/sheepfs/volume.c
index 88a5a94..d43304c 100644
--- a/sheepfs/volume.c
+++ b/sheepfs/volume.c
@@ -54,7 +54,7 @@ struct vdi_inode {
#define SOCKET_POOL_SIZE 31
/*
* Socket pool is used for FUSE read threads, which use threads
- * to simulate aysnc read. All sockets point to the same gateway
+ * to simulate async read. All sockets point to the same gateway
*/
int socket_pool[SOCKET_POOL_SIZE];
uatomic_bool socket_in_use[SOCKET_POOL_SIZE];
@@ -137,7 +137,7 @@ static int volume_rw_object(char *buf, uint64_t oid, size_t size,
assert(vdi);
vdi_id = sd_inode_get_vid(vdi->inode, idx);
if (!vdi_id) {
- /* if object doesn't exist, we'er done */
+ /* if object doesn't exist, we're done */
if (rw == VOLUME_READ) {
memset(buf, 0, size);
goto done;
@@ -459,7 +459,7 @@ int volume_create_entry(const char *entry)
*ch = '\0';
snprintf(path, sizeof(path), "%s/%s", PATH_VOLUME, entry);
- if (shadow_file_exsit(path))
+ if (shadow_file_exist(path))
return 0;
if (init_vdi_info(entry, &vid, &size) < 0)
@@ -519,7 +519,7 @@ int volume_remove_entry(const char *entry)
*ch = '\0';
snprintf(path, sizeof(path), "%s/%s", PATH_VOLUME, entry);
- if (!shadow_file_exsit(path))
+ if (!shadow_file_exist(path))
return -1;
if (shadow_file_getxattr(path, SH_VID_NAME, &vid, SH_VID_SIZE) < 0)
--
1.8.3.2
More information about the sheepdog
mailing list