search for: max_ev

Displaying 8 results from an estimated 8 matches for "max_ev".

Did you mean: max_e
2024 Feb 20
2
Tcl socket server (tcltk) does not work any more on R 4.3.2
Dear list, It seems that something changed between R 4.2.3 and R 4.3 (tested with 4.3.2) that broke the Tcl socket server. Here is a reproducible example: - R process #1 (Tcl socket server): library(tcltk) cmd <- r"( proc accept {chan addr port} { ;# Make a proc to accept connections puts "$addr:$port says [gets $chan]" ;# Receive a string puts $chan goodbye
2011 Mar 30
2
[PATCH] xenstore-stat v2
...""; errx(1, "Usage: %s %s[-h] [-n NR] key", progname, mstr); + case MODE_stat: + mstr = incl_mode ? "stat " : ""; + errx(1, "Usage: %s %s[-h] [-s] key [...]", progname, mstr); } } @@ -286,6 +290,52 @@ do_watch(struct xs_handle *xsh, int max_events) } } +static const char * +perm_type_str(int perm_type) +{ + switch (perm_type) { + case XS_PERM_WRITE: + return "-w"; + case XS_PERM_READ: + return "r-"; + case XS_PERM_READ|XS_PERM_WRITE: + return "rw"; + case XS_PERM_NO...
2017 Mar 03
2
[PATCH 1/2] Use gnulib set_nonblocking_flag function instead of fcntl.
...2d0 100644 --- a/daemon/inotify.c +++ b/daemon/inotify.c @@ -29,6 +29,8 @@ #include <sys/inotify.h> #endif +#include "nonblocking.h" + #include "guestfs_protocol.h" #include "daemon.h" #include "actions.h" @@ -112,8 +114,8 @@ do_inotify_init (int max_events) reply_with_perror ("inotify_init"); return -1; } - if (fcntl (inotify_fd, F_SETFL, O_NONBLOCK) == -1) { - reply_with_perror ("fcntl: O_NONBLOCK"); + if (set_nonblocking_flag (inotify_fd, 1) == -1) { + reply_with_perror ("set_nonblocking_flag")...
2017 Apr 20
6
[PATCH 0/5] generator: daemon: Various simplifications to stubs code.
This is a series of simplifications to the stubs code. It's all refactoring, there is no functional change. Rich.
2012 Feb 01
1
[PATCH] Clarify the error message when unavailable functions are called (RHBZ#679737).
...intf_nowarn (&buf, "--root-directory=%R", root) == -1) { reply_with_perror ("asprintf"); return -1; diff --git a/daemon/inotify.c b/daemon/inotify.c index add1f14..bafc336 100644 --- a/daemon/inotify.c +++ b/daemon/inotify.c @@ -130,7 +130,7 @@ do_inotify_init (int max_events) return 0; #else - NOT_AVAILABLE (-1); + NOT_AVAILABLE (inotify, -1); #endif } @@ -155,7 +155,7 @@ do_inotify_close (void) return 0; #else - NOT_AVAILABLE (-1); + NOT_AVAILABLE (inotify, -1); #endif } @@ -183,7 +183,7 @@ do_inotify_add_watch (const char *path, int mask)...
2013 Jan 03
0
help with NLOPTR
...ality constraints. I get the programs to run but the answer isn't correct because, when it does converge, at least one of the constraints is violated. Any suggestions? Code below Violated constraint (an easy check): x[3]+x[4]+x[5]=L (global parameter); L=12600; you may have to change the max_eval, and the algorithms. I included the constraint gradients (I'm pretty sure they are correct) in case other algorithms are needed. Thanks! ############## Load Packages (mosaic not used here, but was used to get gradients/derivatives) ################# install.packages("nloptr") l...
2009 Aug 12
23
[PATCH 0/23] factor and const-correctness
This started as a simple warning-elimination change. I'll get back to that series shortly ;-) It turned into a factorization and constification exercise during which I got a taste of ocaml. Thanks to Rich Jones for help with a few snippets in generator.ml. The overall result is that many previously-manually-maintained bits from daemon/*.c functions are now hoisted into the automatically-
2007 Jan 02
0
[PATCH 1/4] add scsi-target and IO_CMD_EPOLL_WAIT patches
...imeout in jiffies. ++ */ ++ssize_t eventpoll_aio_wait(struct kiocb *iocb) ++{ ++ struct file *file = iocb->ki_filp; ++ ssize_t ret = -EINVAL; ++ int relative_ms; ++ unsigned long expires; ++ unsigned long now; ++ struct timer_list *timer; ++ ++ if (!is_file_epoll(file) || iocb->ki_nbytes > MAX_EVENTS || ++ iocb->ki_nbytes <= 0) ++ return -EINVAL; ++ ++ if (!iocb->private) { ++ /* ++ * Note that we unconditionally allocate a timer, but we ++ * only use it if a timeout was specified. Otherwise, it ++ * is just a holder for the "infinite" value. ++ */ ++ t...