diff --recursive -u clean/LVM2.2.02.168/lib/mm/memlock.c lvm2.2.02.168/lib/mm/memlock.c --- clean/LVM2.2.02.168/lib/mm/memlock.c 2016-12-01 00:17:29.000000000 +0100 +++ lvm2.2.02.168/lib/mm/memlock.c 2020-01-09 13:23:14.017310025 +0100 @@ -150,6 +150,7 @@ static void _allocate_memory(void) { +#if 0 #ifndef VALGRIND_POOL void *stack_mem; struct rlimit limit; @@ -208,11 +209,14 @@ for (i = 0; i < area; ++i) free(areas[i]); #endif +#endif } static void _release_memory(void) { +#if 0 free(_malloc_mem); +#endif } /* @@ -288,7 +292,7 @@ if (lock == LVM_MLOCK) { if (mlock((const void*)from, sz) < 0) { - log_sys_error("mlock", line); + //log_sys_error("mlock", line); return 0; } } else { diff --recursive -u clean/LVM2.2.02.168/libdm/libdm-stats.c lvm2.2.02.168/libdm/libdm-stats.c --- clean/LVM2.2.02.168/libdm/libdm-stats.c 2016-12-01 00:17:30.000000000 +0100 +++ lvm2.2.02.168/libdm/libdm-stats.c 2020-01-09 13:23:14.017310025 +0100 @@ -17,7 +17,24 @@ #include "dmlib.h" +#if 0 #include "math.h" /* log10() */ +#else +static int ilog10(double x) +{ + int e = 0; + + while(x > 10) + { + e++; + x = x / 10; + } + + return e; +} +#endif + + #include #include @@ -502,7 +519,11 @@ while(entry >= bins) { value = (double) (entry--)->upper; /* Use lround to avoid size_t -> double cast warning. */ +#if 0 hist_len += 1 + (size_t) lround(log10(value / scale)); +#else + hist_len += 1 + ilog10(value / scale); +#endif if (entry != bins) hist_len++; /* ',' */ } @@ -1746,7 +1767,11 @@ } /* length of region_id or range start in characters */ +#if 0 id_len = (i) ? 1 + (size_t) log10(i) : 1; +#else + id_len = (i) ? 1 + ilog10(i) : 1; +#endif buflen += id_len; j = i; do @@ -1761,7 +1786,11 @@ /* handle range */ if (i != j) { /* j is always > i, which is always >= 0 */ +#if 0 id_len = 1 + (size_t) log10(j); +#else + id_len = 1 + ilog10(j); +#endif buflen += id_len + 1; /* range end plus "-" */ } buflen++; diff --recursive -u clean/LVM2.2.02.168/libdm/Makefile.in lvm2.2.02.168/libdm/Makefile.in --- clean/LVM2.2.02.168/libdm/Makefile.in 2016-12-01 00:17:30.000000000 +0100 +++ lvm2.2.02.168/libdm/Makefile.in 2020-01-09 13:23:14.017310025 +0100 @@ -56,7 +56,8 @@ CFLAGS += $(UDEV_CFLAGS) $(VALGRIND_CFLAGS) -LIBS += $(SELINUX_LIBS) $(UDEV_LIBS) $(PTHREAD_LIBS) $(M_LIBS) +#LIBS += $(SELINUX_LIBS) $(UDEV_LIBS) $(PTHREAD_LIBS) $(M_LIBS) +LIBS += $(SELINUX_LIBS) $(UDEV_LIBS) device-mapper: all diff --recursive -u clean/LVM2.2.02.168/make.tmpl.in lvm2.2.02.168/make.tmpl.in --- clean/LVM2.2.02.168/make.tmpl.in 2016-12-01 00:17:30.000000000 +0100 +++ lvm2.2.02.168/make.tmpl.in 2020-01-09 13:23:14.017310025 +0100 @@ -142,7 +142,7 @@ M_INSTALL_PROGRAM = -m 555 M_INSTALL_DATA = -m 444 endif -INSTALL_PROGRAM = $(INSTALL) $(M_INSTALL_PROGRAM) $(STRIP) +INSTALL_PROGRAM = $(INSTALL) $(M_INSTALL_PROGRAM) $(STRIP_ARG) INSTALL_DATA = $(INSTALL) -p $(M_INSTALL_DATA) INSTALL_WDATA = $(INSTALL) -p -m 644 @@ -260,8 +260,8 @@ #CFLAGS += -pg #LDFLAGS += -pg -STRIP= -#STRIP = -s +STRIP_ARG= +#STRIP_ARG = -s LVM_VERSION := $(shell cat $(top_srcdir)/VERSION) diff --recursive -u clean/LVM2.2.02.168/tools/lvmcmdline.c lvm2.2.02.168/tools/lvmcmdline.c --- clean/LVM2.2.02.168/tools/lvmcmdline.c 2016-12-01 00:17:32.000000000 +0100 +++ lvm2.2.02.168/tools/lvmcmdline.c 2020-01-09 13:23:49.057418263 +0100 @@ -1817,6 +1817,7 @@ { int err = is_valid_fd(STDERR_FILENO); +#if 0 if (!is_valid_fd(STDIN_FILENO) && !(stdin = fopen(_PATH_DEVNULL, "r"))) { if (err) @@ -1841,6 +1842,7 @@ strerror(errno)); return 0; } +#endif return 1; } @@ -2023,7 +2025,7 @@ */ dm_set_name_mangling_mode(DM_STRING_MANGLING_NONE); - if (!(cmd = create_toolcontext(0, NULL, 1, 0, + if (!(cmd = create_toolcontext(0, NULL, 0, 0, set_connections, set_filters))) { udev_fin_library_context(); return_NULL;