The creation of the repeater fifo in the synaptics driver looks dubious. The 
file mode should be ORed with the S_IFIFO flag and the dev parameter should 
be null. The mknod(3p) man page suggests using mkfifo instead.

The following patch (compile tested only) uses mkfifo and the symbolic names 
for the file modes.

Signed-off-by: Magnus Kessler <[EMAIL PROTECTED]>

diff --git a/src/synaptics.c b/src/synaptics.c
index 7b5e6d5..f0286ba 100644
--- a/src/synaptics.c
+++ b/src/synaptics.c
@@ -503,13 +503,11 @@ static void set_repeater_fifo(LocalDevicePtr local)
     SynapticsPrivate *priv = local->private;
     pointer optList;
     char *repeater;
-    int status;
 
     repeater = xf86SetStrOption(local->options, "Repeater", NULL);
     if (repeater) {
 	/* create repeater fifo */
-	status = mknod(repeater, 666, S_IFIFO);
-	if ((status != 0) && (status != EEXIST)) {
+	if (mkfifo(repeater, S_IWUSR|S_IRUSR|S_IWGRP|S_IRGRP|S_IWOTH|S_IROTH)) {
 	    xf86Msg(X_ERROR, "%s can't create repeater fifo\n", local->name);
 	} else {
 	    /* open the repeater fifo */

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
xorg mailing list
xorg@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/xorg

Reply via email to