[dm-devel] shared snapshot LVM patch compile error

devicemapper niko devicemapper.niko at gmail.com
Mon Mar 14 12:32:57 UTC 2011


less arguments of lv_info in lvm-shared-merge-dont-delete.patch caused this
error,
origin_only should be 0 ? I didn't look inside the code,so ask you guys

in lvm-shared-merge-dont-delete.patch
Index: LVM2.2.02.73/lib/metadata/lv_manip.c
===================================================================
--- LVM2.2.02.73.orig/lib/metadata/lv_manip.c   2010-09-10
19:15:20.000000000 +0200
+++ LVM2.2.02.73/lib/metadata/lv_manip.c        2010-09-10
19:15:33.000000000 +0200
@@ -2354,6 +2354,38 @@ int lv_remove_with_dependencies(struct c
                struct logical_volume *origin = origin_from_cow(lv);
                /* Remove shared snapshot's virtual snapshots first */
                if (lv_is_multisnap_origin(origin)) {
+                       if (!level) {
+                               int origin_active, merging;
+                               struct lvinfo info;
+                               if (!lv_info(cmd, origin, &info, 0, 0))
{                            -----------------> here
+                                       log_error("Check for existence of
snapshot "
+                                                 "origin '%s' failed.",
origin->name);
+                                       return 0;
+                               }


gcc -c -I. -I../include -DHAVE_CONFIG_H -DDM_IOCTLS -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC -Wall -Wundef -Wshadow
-Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations
-Wnested-externs -Winline -Wmissing-noreturn -Wformat-security
-Wredundant-decls -O2 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2
-fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic
-fPIC -Wall -Wundef -Wshadow -Wcast-align -Wwrite-strings
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
-Wmissing-noreturn -Wformat-security -Wredundant-decls -O2
locking/no_locking.c -o locking/no_locking.o
gcc -c -I. -I../include -DHAVE_CONFIG_H -DDM_IOCTLS -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC -Wall -Wundef -Wshadow
-Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations
-Wnested-externs -Winline -Wmissing-noreturn -Wformat-security
-Wredundant-decls -O2 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2
-fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic
-fPIC -Wall -Wundef -Wshadow -Wcast-align -Wwrite-strings
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
-Wmissing-noreturn -Wformat-security -Wredundant-decls -O2 log/log.c -o
log/log.o
gcc -c -I. -I../include -DHAVE_CONFIG_H -DDM_IOCTLS -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC -Wall -Wundef -Wshadow
-Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations
-Wnested-externs -Winline -Wmissing-noreturn -Wformat-security
-Wredundant-decls -O2 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2
-fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic
-fPIC -Wall -Wundef -Wshadow -Wcast-align -Wwrite-strings
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
-Wmissing-noreturn -Wformat-security -Wredundant-decls -O2
metadata/lv_manip.c -o metadata/lv_manip.o
metadata/lv_manip.c: In function 'lv_remove_with_dependencies':
metadata/lv_manip.c:2360: warning: passing argument 3 of 'lv_info' makes
integer from pointer without a cast
../include/activate.h:80: note: expected 'unsigned int' but argument is of
type 'struct lvinfo *'
metadata/lv_manip.c:2360: error: too few arguments to function 'lv_info'
make[1]: *** [metadata/lv_manip.o] Error 1
make[1]: Leaving directory `/root/rpmbuild/BUILD/LVM2.2.02.72/lib'
make: *** [lib] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.RpT3fj (%build)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/dm-devel/attachments/20110314/85b984d2/attachment.htm>


More information about the dm-devel mailing list