Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:12.2
xen
xenconsole-no-multiple-connections.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File xenconsole-no-multiple-connections.patch of Package xen
Index: xen-4.1.2-testing/tools/console/client/main.c =================================================================== --- xen-4.1.2-testing.orig/tools/console/client/main.c +++ xen-4.1.2-testing/tools/console/client/main.c @@ -96,6 +96,7 @@ static int get_pty_fd(struct xs_handle * * Assumes there is already a watch set in the store for this path. */ { struct timeval tv; + struct flock lock; fd_set watch_fdset; int xs_fd = xs_fileno(xs), pty_fd = -1; int start, now; @@ -122,6 +123,12 @@ static int get_pty_fd(struct xs_handle * if (pty_fd == -1) err(errno, "Could not open tty `%s'", pty_path); + memset(&lock, 0, sizeof(lock)); + lock.l_type = F_WRLCK; + lock.l_whence = SEEK_SET; + if (fcntl(pty_fd, F_SETLK, &lock) != 0) + err(errno, "Could not lock tty '%s'", + pty_path); free(pty_path); } }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor