[Sheepdog] [PATCH v3] Don't report an error for blocks not stored locally
Liu Yuan
namei.unix at gmail.com
Sat Dec 17 12:31:33 CET 2011
On 12/17/2011 05:00 PM, Chris Webb wrote:
> Signed-off-by: Chris Webb <chris at arachsys.com>
> ---
> Oops, previous patch was incorrectly edited and wouldn't apply! Fixed
> properly this time.
>
> sheep/simple_store.c | 10 +++++++----
> 1 files changed, 7 insertions(+), 4 deletions(-)
>
> diff --git a/sheep/simple_store.c b/sheep/simple_store.c
> index 424589f..3f2c241 100644
> --- a/sheep/simple_store.c
> +++ b/sheep/simple_store.c
> @@ -76,17 +76,20 @@ static int simple_store_open(uint64_t oid, struct siocb *iocb, int create)
>
> ret = open(path.buf, flags, def_fmode);
> if (ret < 0) {
> - eprintf("failed to open %s: %m\n", path.buf);
> if (errno == ENOENT) {
> struct stat s;
>
> - ret = SD_RES_NO_OBJ;
> if (stat(obj_path, &s) < 0) {
> /* store directory is corrupted */
> - eprintf("corrupted\n");
> + eprintf("store directory corrupted: %m\n");
since output in the eprintf already says it, then would better remove
the comment above in passing.
Thanks,
Yuan
More information about the sheepdog
mailing list