]> xenbits.xen.org Git - xenclient/ioemu.git/commitdiff
If the hid device is busy try again.
authorJean Guyader <jean.guyader@eu.citrix.com>
Tue, 24 Mar 2009 16:59:05 +0000 (16:59 +0000)
committerJean Guyader <jean.guyader@eu.citrix.com>
Tue, 24 Mar 2009 16:59:05 +0000 (16:59 +0000)
hid-linux.c

index d091c54c44d61622e354eb5f5538f62b6e1fd888..4ec6bddea0fae9559820f6a14fb3c8f7c6082100 100644 (file)
@@ -374,6 +374,9 @@ static int hid_linux_grab_devices(int grab, int *fd)
            if ((rc = ioctl(*fd, EVIOCGRAB, grab)) == -1)
            {
                char *er;
+
+               if (errno == EBUSY)
+                   continue;
                er = strerror(errno);
                DEBUG("ioctl(%d, EVOCGRAB) failed, %s\n", *fd, er);
                return 0;