Blame SOURCES/0037-RHBZ-768873-fix-rename.patch

671555
---
671555
 libmultipath/devmapper.c |   45 ---------------------------------------------
671555
 libmultipath/devmapper.h |    1 -
671555
 libmultipath/propsel.c   |    2 --
671555
 3 files changed, 48 deletions(-)
671555
671555
Index: multipath-tools-130222/libmultipath/devmapper.c
671555
===================================================================
671555
--- multipath-tools-130222.orig/libmultipath/devmapper.c
671555
+++ multipath-tools-130222/libmultipath/devmapper.c
671555
@@ -917,51 +917,6 @@ out:
671555
 	return r;
671555
 }
671555
 
671555
-extern char *
671555
-dm_get_name(char *uuid)
671555
-{
671555
-	struct dm_task *dmt;
671555
-	struct dm_info info;
671555
-	char *prefixed_uuid, *name = NULL;
671555
-	const char *nametmp;
671555
-
671555
-	dmt = dm_task_create(DM_DEVICE_INFO);
671555
-	if (!dmt)
671555
-		return NULL;
671555
-
671555
-	prefixed_uuid = MALLOC(UUID_PREFIX_LEN + strlen(uuid) + 1);
671555
-	if (!prefixed_uuid) {
671555
-		condlog(0, "cannot create prefixed uuid : %s",
671555
-			strerror(errno));
671555
-		goto freeout;
671555
-	}
671555
-	sprintf(prefixed_uuid, UUID_PREFIX "%s", uuid);
671555
-	if (!dm_task_set_uuid(dmt, prefixed_uuid))
671555
-		goto freeout;
671555
-
671555
-	if (!dm_task_run(dmt))
671555
-		goto freeout;
671555
-
671555
-	if (!dm_task_get_info(dmt, &info) || !info.exists)
671555
-		goto freeout;
671555
-
671555
-	nametmp = dm_task_get_name(dmt);
671555
-	if (nametmp && strlen(nametmp)) {
671555
-		name = MALLOC(strlen(nametmp) + 1);
671555
-		if (name)
671555
-			strcpy(name, nametmp);
671555
-	} else {
671555
-		condlog(2, "%s: no device-mapper name found", uuid);
671555
-	}
671555
-
671555
-freeout:
671555
-	if (prefixed_uuid)
671555
-		FREE(prefixed_uuid);
671555
-	dm_task_destroy(dmt);
671555
-
671555
-	return name;
671555
-}
671555
-
671555
 int
671555
 dm_geteventnr (char *name)
671555
 {
671555
Index: multipath-tools-130222/libmultipath/devmapper.h
671555
===================================================================
671555
--- multipath-tools-130222.orig/libmultipath/devmapper.h
671555
+++ multipath-tools-130222/libmultipath/devmapper.h
671555
@@ -40,7 +40,6 @@ int dm_remove_partmaps (const char * map
671555
 int dm_get_uuid(char *name, char *uuid);
671555
 int dm_get_info (char * mapname, struct dm_info ** dmi);
671555
 int dm_rename (char * old, char * new);
671555
-char * dm_get_name(char * uuid);
671555
 int dm_reassign(const char * mapname);
671555
 int dm_reassign_table(const char *name, char *old, char *new);
671555
 int dm_setgeometry(struct multipath *mpp);
671555
Index: multipath-tools-130222/libmultipath/propsel.c
671555
===================================================================
671555
--- multipath-tools-130222.orig/libmultipath/propsel.c
671555
+++ multipath-tools-130222/libmultipath/propsel.c
671555
@@ -263,8 +263,6 @@ select_alias (struct multipath * mp)
671555
 					conf->bindings_file, mp->alias_prefix, conf->bindings_read_only);
671555
 		}
671555
 		if (mp->alias == NULL)
671555
-			mp->alias = dm_get_name(mp->wwid);
671555
-		if (mp->alias == NULL)
671555
 			mp->alias = STRDUP(mp->wwid);
671555
 	}
671555