Date: Mon, 16 Jun 2008 14:27:26 +0200
From: Andi Kleen <andi@firstfloor.org>
To: cpw@sgi.com
Cc: linux-numa@sgi.com

Subject: [PATCH] Remove one more complain user

Remove complain finally
Missed on user of complain in the v1 compat function earlier.
Replace with numa_error

Not 100% if this one doesn't need to exit(1) unconditionally.
But who uses cpumask() anyways? I don't remember adding it in numactl v1

Index: numactl-2.0.0/numa.h
===================================================================
--- numactl-2.0.0.orig/numa.h
+++ numactl-2.0.0/numa.h
@@ -484,7 +484,6 @@ static inline nodemask_t nodemask_compat
 	return mask;
 }
 
-void complain(char *fmt, ...);
 static inline unsigned long *cpumask_compat(char *c, int *ncpus)
 {
 	struct bitmask *tp;
@@ -493,8 +492,10 @@ static inline unsigned long *cpumask_com
 	tp = numa_parse_cpustring(c);
 	*ncpus = tp->size;
 	cpubuf = calloc(tp->size,1);
-        if (!cpubuf)
-                complain("Out of memory");
+        if (!cpubuf) {
+                numa_error("Out of memory");
+		return NULL;
+	}
 	memcpy(cpubuf, tp->maskp, tp->size/8);
 	numa_bitmask_free(tp);
 	return cpubuf;
