tools/libs/*: freebsd remove unused code

"tools/libs/*: Use O_CLOEXEC on Linux and FreeBSD" left some dead code
in the FreeBSD case, which breaks the build on that platform.

Also fix a typo "uint_32".

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
This commit is contained in:
Ian Campbell committed 2016-01-25 14:20:08 +00:00
1 parent 5e0da2ac71
commit d322b7f4c2
3 files changed
+1 -17

No files matched your search

-8
View File
@@ -35,7 +35,6 @@
int osdep_xencall_open(xencall_handle *xcall)
{
int saved_errno;
int fd = open(PRIVCMD_DEV, O_RDWR|O_CLOEXEC);
/*
@@ -53,13 +52,6 @@ int osdep_xencall_open(xencall_handle *xcall)
xcall->fd = fd;
return 0;
error:
saved_errno = errno;
close(fd);
errno = saved_errno;
return -1;
}
int osdep_xencall_close(xencall_handle *xcall)
+1 -1
View File
@@ -74,7 +74,7 @@ evtchn_port_or_error_t xenevtchn_bind_unbound_port(xenevtchn_handle *xce, uint32
}
evtchn_port_or_error_t
xenevtchn_bind_interdomain(xenevtchn_handle *xce, uint_32 domid, evtchn_port_t remote_port)
xenevtchn_bind_interdomain(xenevtchn_handle *xce, uint32_t domid, evtchn_port_t remote_port)
{
int ret, fd = xce->fd;
struct ioctl_evtchn_bind_interdomain bind;
-8
View File
@@ -33,7 +33,6 @@
int osdep_xenforeignmemory_open(xenforeignmemory_handle *fmem)
{
int saved_errno;
int fd = open(PRIVCMD_DEV, O_RDWR|O_CLOEXEC);
if ( fd == -1 )
@@ -45,13 +44,6 @@ int osdep_xenforeignmemory_open(xenforeignmemory_handle *fmem)
fmem->fd = fd;
return 0;
error:
saved_errno = errno;
close(fd);
errno = saved_errno;
return -1;
}
int osdep_xenforeignmemory_close(xenforeignmemory_handle *fmem)
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.