From: Christof Schmitt Subject: [patch 1/2] multipath-tools: Assign correct pointer from REALLOC Date: Thu, 22 Jul 2010 18:36:47 +0200 Message-ID: <20100722163918.159875000@de.ibm.com> References: <20100722163646.585967000@de.ibm.com> Reply-To: device-mapper development Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline; filename=fix-vector-realloc.diff List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com To: Christophe Varoqui Cc: Christof Schmitt , dm-devel@redhat.com List-Id: dm-devel.ids From: Christof Schmitt Assign the pointer returned from REALLOC to v->slot; this is the memory area to be changed. Signed-off-by: Christof Schmitt --- libmultipath/vector.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/libmultipath/vector.c +++ b/libmultipath/vector.c @@ -96,7 +96,7 @@ vector_del_slot(vector v, int slot) v->slot = NULL; } else - v = REALLOC(v->slot, sizeof (void *) * v->allocated); + v->slot = REALLOC(v->slot, sizeof (void *) * v->allocated); } void