Sophie

Sophie

distrib > Mandriva > 2009.0 > i586 > by-pkgid > e9017f7a0821d8ca37c25028b3d30f00 > files > 3

exmap-console-0.4.1-5mdv2009.0.src.rpm

--- trunk/exmap-console/kernel/exmap.c	2006/10/24 18:45:11	134
+++ trunk/exmap-console/kernel/exmap.c	2008/09/10 22:12:40	405
@@ -392,7 +392,11 @@
 	struct task_struct *tsk;
 	int errcode = -EINVAL;
 
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
+	tsk = find_task_by_vpid(pid);
+#else
 	tsk = find_task_by_pid(pid);
+#endif
 	if (tsk == NULL) {
 		printk (KERN_ALERT
 			"/proc/%s: can't find task for pid %d\n",
@@ -507,7 +511,7 @@
 							NULL);
 
 	if (exmap_proc_file == NULL) {
-		remove_proc_entry (PROCFS_NAME, &proc_root);
+		remove_proc_entry (PROCFS_NAME, NULL);
 		printk (KERN_ALERT "/proc/%s: could not initialize\n",
 			PROCFS_NAME);
 		return -ENOMEM;
@@ -532,5 +536,5 @@
 void cleanup_module ()
 {
 	printk (KERN_INFO "/proc/%s: remove\n", PROCFS_NAME);
-	remove_proc_entry (PROCFS_NAME, &proc_root);
+	remove_proc_entry (PROCFS_NAME, NULL);
 }