On Mon, Feb 06, 2012 at 04:17:07PM +0800, Wanlong Gao wrote:
fix coding style to be consistent with others.
Signed-off-by: Wanlong Gao <gaowanlong(a)cn.fujitsu.com>
---
daemon/md.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/daemon/md.c b/daemon/md.c
index 41e2c75..5432213 100644
--- a/daemon/md.c
+++ b/daemon/md.c
@@ -244,7 +244,7 @@ do_md_detail(const char *md)
char **ret = NULL;
int size = 0, alloc = 0;
- const char *mdadm[] = { "mdadm", "-D", "--export", md,
NULL };
+ const char *mdadm[] = {"mdadm", "-D", "--export", md,
NULL };
I think we should either have both spaces or neither space :-)
r = commandv (&out, &err, mdadm);
if (r == -1) {
reply_with_error ("%s", err);
@@ -315,16 +315,16 @@ error:
}
int
-do_md_stop(const char *md)
+do_md_stop (const char *md)
{
int r;
char *err = NULL;
- const char *mdadm[] = { "mdadm", "--stop", md, NULL};
- r = commandv(NULL, &err, mdadm);
+ const char *mdadm[] = {"mdadm", "--stop", md, NULL};
+ r = commandv (NULL, &err, mdadm);
if (r == -1) {
- reply_with_error("%s", err);
- free(err);
+ reply_with_error ("%s", err);
+ free (err);
return -1;
}
free (err);
--
1.7.9
Yes, in general these sorts of cleanups are good.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
virt-top is 'top' for virtual machines. Tiny program with many
powerful monitoring features, net stats, disk stats, logging, etc.
http://et.redhat.com/~rjones/virt-top