mtd/include/linux/mtd compatmac.h,1.50,1.51

David Woodhouse dwmw2 at infradead.org
Fri May 16 06:06:56 EDT 2003


Update of /home/cvs/mtd/include/linux/mtd
In directory phoenix.infradead.org:/tmp/cvs-serv9232

Modified Files:
	compatmac.h 
Log Message:
Fix daemonize


Index: compatmac.h
===================================================================
RCS file: /home/cvs/mtd/include/linux/mtd/compatmac.h,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -r1.50 -r1.51
--- compatmac.h	15 May 2003 17:10:07 -0000	1.50
+++ compatmac.h	16 May 2003 10:06:53 -0000	1.51
@@ -579,18 +579,15 @@
 #endif
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,61)
-static inline void __daemonize25(const char *fmt, ...)
+static inline void __daemonize_modvers(void)
 {
-	va_list args;
-
-	va_start(args, fmt);
-	vsnprintf(current->comm, sizeof(current->comm), fmt, args);
-	va_end(args);
-
 	daemonize();
 }
 #undef daemonize
-#define daemonize __daemonize25
+#define daemonize(fmt, ...) do {						\
+	snprintf(current->comm, sizeof(current->comm), fmt ,##__VA_ARGS__);	\
+	__daemonize_modvers();							\
+	} while(0)
 
 static inline int __dequeue_signal25(struct task_struct *tsk, sigset_t *mask, siginfo_t *info)
 {




More information about the linux-mtd-cvs mailing list