[sheepdog] [PATCH] recovery: use passed epoch in fetch_object_list()

MORITA Kazutaka morita.kazutaka at lab.ntt.co.jp
Wed May 29 10:36:06 CEST 2013


At Tue, 28 May 2013 14:24:08 +0800,
Liu Yuan wrote:
> 
> Signed-off-by: Liu Yuan <namei.unix at gmail.com>
> ---
>  sheep/recovery.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/sheep/recovery.c b/sheep/recovery.c
> index 2bd3a46..dba89fb 100644
> --- a/sheep/recovery.c
> +++ b/sheep/recovery.c
> @@ -672,7 +672,7 @@ static uint64_t *fetch_object_list(struct sd_node *e, uint32_t epoch,
>  retry:
>  	sd_init_req(&hdr, SD_OP_GET_OBJ_LIST);
>  	hdr.data_length = buf_size;
> -	hdr.epoch = sys_epoch();
> +	hdr.epoch = epoch;
>  	ret = sheep_exec_req(&e->nid, &hdr, buf);
>  
>  	switch (ret) {

I think the epoch field is not used for non-peer requests.  Removing
the line looks better to me.

Thanks,

Kazutaka



More information about the sheepdog mailing list