Skip to contentSkip to conversation

cluster/gfs-kernel/src/nolock main.c

Cluster-devel [email protected] 1 participant 1 message Jun 26, 2006

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/cluster
Module name: cluster
Changes by: teigland at sourceware.org 2006-06-26 21:21:46

Modified files:
gfs-kernel/src/nolock: main.c

Log message:
posix_test_lock() args updated for 2.6.17

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/nolock/main.c.diff?cvsroot=cluster&r1=1.13&r2=1.14

gfs-kernel/src/nolock/main.c +5 -4
@@ -182,13 +182,14 @@
 static int nolock_plock_get(lm_lockspace_t *lockspace, struct lm_lockname *name,
 			    struct file *file, struct file_lock *fl)
 {
-	struct file_lock *tmp;
+	struct file_lock tmp;
+	int ret;
 
 	lock_kernel();
-	tmp = posix_test_lock(file, fl);
+	ret = posix_test_lock(file, fl, &tmp);
 	fl->fl_type = F_UNLCK;
-	if (tmp)
-		memcpy(fl, tmp, sizeof(struct file_lock));
+	if (ret)
+		memcpy(fl, &tmp, sizeof(struct file_lock));
 	unlock_kernel();
 
 	return 0;