From 75691760d2cd661d3335442c9e4f032c6e96654b Mon Sep 17 00:00:00 2001 From: krw Date: Fri, 2 May 2014 12:43:10 +0000 Subject: [PATCH] 'for (part == 0; ...)' is not the same as 'for(part = 0; ...)'. Should fix mysterious crashes when twiddling mount points. Too much Marrakesh sun. Pointed out by Owain G. Ainsworth. Thanks! --- sbin/disklabel/editor.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sbin/disklabel/editor.c b/sbin/disklabel/editor.c index e37d5a432a7..71fd9d006f1 100644 --- a/sbin/disklabel/editor.c +++ b/sbin/disklabel/editor.c @@ -1,4 +1,4 @@ -/* $OpenBSD: editor.c,v 1.284 2014/04/21 08:19:38 krw Exp $ */ +/* $OpenBSD: editor.c,v 1.285 2014/05/02 12:43:10 krw Exp $ */ /* * Copyright (c) 1997-2000 Todd C. Miller @@ -1900,7 +1900,7 @@ mpfree(char **mp) if (mp == NULL) return; - for (part == 0; part < MAXPARTITIONS; part++) + for (part = 0; part < MAXPARTITIONS; part++) free(mp[part]); free(mp); -- 2.20.1