[sheepdog] [PATCH] Fix compile warning

Kai Zhang kyle at zelin.io
Tue Jun 4 15:39:05 CEST 2013


Hi Haomai

Actually, I am working on improving cluster-wide snapshot in two ways:
- avoid of reading objects that has exists in local path by reading sha1 value
- parallelise the procedure of reading/loading cluster snapshot

I have send the first version before 0.6.0 released.
And I will send another version soon.

This code will be dropped in this patch.

Please check this http://lists.wpkg.org/pipermail/sheepdog/2013-May/009817.html for more details.

Thanks,
Kyle

On Jun 4, 2013, at 9:25 PM, Haomai Wang <haomaiwang at gmail.com> wrote:

> From: Haomai Wang <haomaiwang at gmail>
> 
> fix complie warning below:
> object_tree.c:112 warning: comparison of distinct pointer types lacks a cast
> 
> Signed-off-by: Haomai Wang <haomaiwang at gmail>
> ---
> collie/farm/object_tree.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/collie/farm/object_tree.c b/collie/farm/object_tree.c
> index f719af6..e29583a 100644
> --- a/collie/farm/object_tree.c
> +++ b/collie/farm/object_tree.c
> @@ -109,7 +109,7 @@ int for_each_object_in_tree(object_handler_func_t func, void *data)
> 	struct object_tree_entry *entry;
> 	uint64_t oid;
> 	size_t size;
> -	void *buf = xmalloc(max(SD_INODE_SIZE, SD_DATA_OBJ_SIZE));
> +	void *buf = xmalloc(max(SD_INODE_SIZE, (size_t)SD_DATA_OBJ_SIZE));
> 	int ret = -1;
> 
> 	while (p) {
> -- 
> 1.7.12.4 (Apple Git-37)
> 
> -- 
> sheepdog mailing list
> sheepdog at lists.wpkg.org
> http://lists.wpkg.org/mailman/listinfo/sheepdog

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wpkg.org/pipermail/sheepdog/attachments/20130604/7d3f3d5b/attachment-0004.html>


More information about the sheepdog mailing list