PERFORCE change 81713 for review

soc-cjones soc-cjones at FreeBSD.org
Tue Aug 9 07:59:56 GMT 2005


http://perforce.freebsd.org/chv.cgi?CH=81713

Change 81713 by soc-cjones at soc-cjones_ishtar on 2005/08/09 07:59:24

	Broken --- we're unable to correctly remove the temporary subdisk.

Affected files ...

.. //depot/projects/soc2005/gvinum/src/sys/geom/vinum/geom_vinum_move.c#5 edit

Differences ...

==== //depot/projects/soc2005/gvinum/src/sys/geom/vinum/geom_vinum_move.c#5 (text+ko) ====

@@ -78,8 +78,11 @@
 	for (i = 0; i < *argc; i++) {
 		snprintf(buf, sizeof(buf), "argv%d", i);
 		object = gctl_get_param(req, buf, NULL);
+		printf("%s -> %s\n", buf, object);
 		if (NULL == object)
-			continue;
+		  continue;
+		if (0 == i)
+		  continue;
 		type = gv_object_type(sc, object);
 		switch (type) {
 		case GV_TYPE_VOL:
@@ -122,7 +125,7 @@
 				gctl_error(req, "unknown drive '%s'", object);
 				return;
 			}
-			gctl_err(req, "no touching drives!");
+			gctl_error(req, "no touching drives!");
 			return 1;
 			err = gv_move_drive(sc, req, d, destination, *flags);
 			if (err)
@@ -200,6 +203,7 @@
 	printf("B (s2->name = %s)\n", s2->name);
 	s2->size = s->size;
 	printf("C\n");
+	strncpy(s2->drive, d->name, GV_MAXSDNAME);
 	s2->drive_sc = d;
 	s2->drive_offset = -1;
 	s2->plex_offset = -1;
@@ -223,6 +227,7 @@
 	gv_update_sd_state(s);
 	printf("J\n");
 	gv_save_config_all(sc);
+	printf("K\n");
 
 	/* TODO -- move data from old sd to new sd. */
 	/* TODO -- delete old sd. */


More information about the p4-projects mailing list