[Ocfs2-tools-devel] [PATCH 2/4] Ocfs2-tools: Fix a minor bug of fswreck.

Joel Becker Joel.Becker at oracle.com
Thu Jun 25 11:57:38 PDT 2009


On Wed, Jun 24, 2009 at 06:44:13PM +0800, Tristan Ye wrote:
> Signed-off-by: Tristan Ye <tristan.ye at oracle.com>

	Please describe the bug and its solution in the commit log.

Joel

> ---
>  fswreck/inode.c |    5 +++++
>  fswreck/main.c  |    2 +-
>  2 files changed, 6 insertions(+), 1 deletions(-)
> 
> diff --git a/fswreck/inode.c b/fswreck/inode.c
> index 377ce08..70e849e 100644
> --- a/fswreck/inode.c
> +++ b/fswreck/inode.c
> @@ -402,6 +402,11 @@ void mess_up_dup_clusters(ocfs2_filesys *fs, enum fsck_type type,
>  	if (err)
>  		FSWRK_COM_FATAL(progname, err);
>  
> +	fprintf(stdout, "DUPLICATE_CLUSTERS: "
> +		"Create two inodes #%"PRIu64" and #%"PRIu64
> +		" by allocating same cluster to them.",
> +		inode1_blkno, inode2_blkno);
> +
>  	ocfs2_free(&buf);
>  }
>  
> diff --git a/fswreck/main.c b/fswreck/main.c
> index 27f79a6..ea15fb7 100644
> --- a/fswreck/main.c
> +++ b/fswreck/main.c
> @@ -420,7 +420,7 @@ int main (int argc, char **argv)
>  		goto bail;
>  	}
>  
> -	for (i = 1; i < NUM_FSCK_TYPE; ++i) {
> +	for (i = 0; i < NUM_FSCK_TYPE; ++i) {
>  		if (corrupt[i]) {
>  			if (prompt_codes[i].func)
>  				prompt_codes[i].func(fs, prompt_codes[i].type,
> -- 
> 1.5.5
> 
> 
> _______________________________________________
> Ocfs2-tools-devel mailing list
> Ocfs2-tools-devel at oss.oracle.com
> http://oss.oracle.com/mailman/listinfo/ocfs2-tools-devel

-- 

"This is the end, beautiful friend.
 This is the end, my only friend the end
 Of our elaborate plans, the end
 Of everything that stands, the end
 No safety or surprise, the end
 I'll never look into your eyes again."

Joel Becker
Principal Software Developer
Oracle
E-mail: joel.becker at oracle.com
Phone: (650) 506-8127



More information about the Ocfs2-tools-devel mailing list