diff options
author | shrinivasan ganapathy <shrinivasanganapathy@gmail.com> | 2017-10-10 11:32:11 -0700 |
---|---|---|
committer | shrinivasan ganapathy <shrinivasanganapathy@gmail.com> | 2017-10-10 11:32:11 -0700 |
commit | 2057491539259158e980c03a4a07740ce0dfbb13 (patch) | |
tree | 4ebac9dbf9dbef278b1dd1a175343f68b8b81ec3 /vcl-ldpreload/src/libvcl-ldpreload/vcom.c | |
parent | e366e723d9afac1af35529a0e959e7226d000d6f (diff) |
LD_PRELOAD stub identified system calls
- stub identifed unimplemented system call
to return EOPNOTSUPP(95)
Change-Id: I4f4a78717059f224bc695a0d32d4f0417dc46bd4
Signed-off-by: shrinivasan ganapathy <shrinivasanganapathy@gmail.com>
Diffstat (limited to 'vcl-ldpreload/src/libvcl-ldpreload/vcom.c')
-rw-r--r-- | vcl-ldpreload/src/libvcl-ldpreload/vcom.c | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/vcl-ldpreload/src/libvcl-ldpreload/vcom.c b/vcl-ldpreload/src/libvcl-ldpreload/vcom.c index e148ce0..3160d1d 100644 --- a/vcl-ldpreload/src/libvcl-ldpreload/vcom.c +++ b/vcl-ldpreload/src/libvcl-ldpreload/vcom.c @@ -2899,6 +2899,66 @@ epoll_pwait (int __epfd, struct epoll_event *__events, return 0; } +/* Poll the file descriptors described by the NFDS structures starting at + FDS. If TIMEOUT is nonzero and not -1, allow TIMEOUT milliseconds for + an event to occur; if TIMEOUT is -1, block until an event occurs. + Returns the number of file descriptors with events, zero if timed out, + or -1 for errors. + + This function is a cancellation point and therefore not marked with + __THROW. */ +int +vcom_poll (struct pollfd *__fds, nfds_t __nfds, int __timeout) +{ + if (vcom_init () != 0) + { + return -1; + } + + return -EOPNOTSUPP; +} + +int +poll (struct pollfd *__fds, nfds_t __nfds, int __timeout) +{ + int rv = 0; + + errno = EOPNOTSUPP; + rv = -1; + return rv; +} + +#ifdef __USE_GNU +/* Like poll, but before waiting the threads signal mask is replaced + with that specified in the fourth parameter. For better usability, + the timeout value is specified using a TIMESPEC object. + + This function is a cancellation point and therefore not marked with + __THROW. */ +int vcom_ppoll (struct pollfd *__fds, nfds_t __nfds, + const struct timespec *__timeout, + const __sigset_t *__ss) +{ + if (vcom_init () != 0) + { + return -1; + } + + return -EOPNOTSUPP; +} + +int ppoll (struct pollfd *__fds, nfds_t __nfds, + const struct timespec *__timeout, + const __sigset_t *__ss) +{ + int rv = 0; + + errno = EOPNOTSUPP; + rv = -1; + return rv; +} +#endif + void CONSTRUCTOR_ATTRIBUTE vcom_constructor (void); void DESTRUCTOR_ATTRIBUTE vcom_destructor (void); |