cluster gfs/gfs_mkfs/main.c gfs2/mkfs/main_mkfs.c
CVSROOT: /cvs/cluster
Module name: cluster
Changes by: rohara at sourceware.org 2007-07-12 15:45:44
Modified files:
gfs/gfs_mkfs : main.c
gfs2/mkfs : main_mkfs.c
Log message:
Fix bug where mkfs always exits with EXIT_FAILURE.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs/gfs_mkfs/main.c.diff?cvsroot=cluster&r1=1.7&r2=1.8
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs2/mkfs/main_mkfs.c.diff?cvsroot=cluster&r1=1.15&r2=1.16
gfs/gfs_mkfs/main.c +2 -5
@@ -262,16 +262,13 @@if (strcmp (device, mnt->mnt_fsname) ==0 ) {printf ("cannot create filesystem: " );printf ("%s appears to be mounted\n" , device); -break ; +endmntent (fp); +exit (EXIT_FAILURE ); } }endmntent (fp); -if (fp !=NULL ) { -exit (EXIT_FAILURE ); - } -return ; }
gfs2/mkfs/main_mkfs.c +2 -4
@@ -302,16 +302,14 @@if (strcmp (device, mnt->mnt_fsname) ==0 ) {printf ("cannot create filesystem: " );printf ("%s appears to be mounted\n" , device); +endmntent (fp); +exit (EXIT_FAILURE );break ; } }endmntent (fp); -if (fp !=NULL ) { -exit (EXIT_FAILURE ); - } -return ; }