diff usr/src/cmd/mdb/common/mdb/mdb_modapi.c @ 3277:153d1be61d60

4432333 bus error executing bogus pipeline 6309373 mdb dumps core in elt_print with assertion failure 6381180 mdb's genunix module uses DEBUG version of struct, doesn't work on non-DEBUG kernels 6385034 ::head / mdb_set_pipe() interact badly with VCBs 6450326 mdb corrupt frame list when dcmd aborts pipe
author af
date Tue, 19 Dec 2006 01:50:12 -0800
parents 68f95e015346
children 440e36e26761
line wrap: on
line diff
--- a/usr/src/cmd/mdb/common/mdb/mdb_modapi.c	Tue Dec 19 01:23:32 2006 -0800
+++ b/usr/src/cmd/mdb/common/mdb/mdb_modapi.c	Tue Dec 19 01:50:12 2006 -0800
@@ -2,9 +2,8 @@
  * CDDL HEADER START
  *
  * The contents of this file are subject to the terms of the
- * Common Development and Distribution License, Version 1.0 only
- * (the "License").  You may not use this file except in compliance
- * with the License.
+ * Common Development and Distribution License (the "License").
+ * You may not use this file except in compliance with the License.
  *
  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  * or http://www.opensolaris.org/os/licensing.
@@ -20,7 +19,7 @@
  * CDDL HEADER END
  */
 /*
- * Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
+ * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
@@ -730,7 +729,7 @@
 	if (cp != NULL) {
 		size_t nbytes = sizeof (uintptr_t) * p->pipe_len;
 
-		mdb_addrvec_destroy(&cp->c_addrv);
+		mdb_cmd_reset(cp);
 		cp->c_addrv.ad_data = mdb_alloc(nbytes, UM_SLEEP);
 		bcopy(p->pipe_data, cp->c_addrv.ad_data, nbytes);
 		cp->c_addrv.ad_nelems = p->pipe_len;