search for: extraarg

Displaying 20 results from an estimated 33 matches for "extraarg".

Did you mean: extra_arg
2013 May 21
1
making makepredictcall() work
...he idea is to produce "safe" predictions from a model using this function. As I have seen, to do this I need to use makepredictcall(). Consider the following toy example: myns <- function (x, df = NULL, knots = NULL, intercept = FALSE, Boundary.knots = range(x), extraArg = 0) { ns.x <- if (is.null(knots)) { ns(x, df = df, intercept = intercept, Boundary.knots = Boundary.knots) } else { ns(x, knots = knots, intercept = intercept, Boundary.knots = Boundary.knots) } out <- ns.x + extraArg attr(out, "class")...
2023 Apr 16
0
sum(), min(), max(), prod() vs. named arguments in ...
...t something confusing > happens to the arguments: according to the method, the dots contain > what I would expect them to contain (only the numbers to sum), but when > calling NextMethod() to compute the actual sum, extra arguments get > processed: > > sum.foo <- function(..., ExtraArg = 999, na.rm = FALSE) { > print(ExtraArg) > str(...) > NextMethod(generic = 'sum', ..., na.rm = na.rm) > } > sum(structure(100, class = 'foo')) > # [1] 999 > # 'foo' num 100 > # [1] 100 > sum(structure(100, class = 'foo'), ExtraArg =...
2014 Nov 23
0
[PATCH 2/3] New API: guestfs_blockdev_setra: Adjust readahead for filesystems and devices.
...generator/actions.ml | 14 ++++++++++++++ 2 files changed, 34 insertions(+), 10 deletions(-) diff --git a/daemon/blockdev.c b/daemon/blockdev.c index 8a7b1a8..6e8821d 100644 --- a/daemon/blockdev.c +++ b/daemon/blockdev.c @@ -62,7 +62,7 @@ call_blockdev (const char *device, const char *switc, int extraarg, int prints) */ udev_settle (); - if (extraarg > 0) { + if (extraarg >= 0) { snprintf (buf, sizeof buf, "%d", extraarg); argv[2] = buf; argv[3] = device; @@ -89,33 +89,43 @@ call_blockdev (const char *device, const char *switc, int extraarg, int prints) }...
2023 Apr 14
0
sum(), min(), max(), prod() vs. named arguments in ...
...ently, they are dispatched, but something confusing happens to the arguments: according to the method, the dots contain what I would expect them to contain (only the numbers to sum), but when calling NextMethod() to compute the actual sum, extra arguments get processed: sum.foo <- function(..., ExtraArg = 999, na.rm = FALSE) { print(ExtraArg) str(...) NextMethod(generic = 'sum', ..., na.rm = na.rm) } sum(structure(100, class = 'foo')) # [1] 999 # 'foo' num 100 # [1] 100 sum(structure(100, class = 'foo'), ExtraArg = -1) # [1] -1 # 'foo' num 100 # <--...
2014 Nov 23
7
[PATCH 0/3] patches needed for virt-bmap
See http://rwmj.wordpress.com/2014/11/23/mapping-files-to-disk/
2014 Nov 24
2
[PATCH v2 0/2] patches needed for virt-bmap
Does *not* incorporate changes suggested by Pino yet. Rich.
2012 Feb 06
2
[PATCH 1/2] Revert "daemon: Run udev_settle after pwrite-device finishes."
From: "Richard W.M. Jones" <rjones at redhat.com> This reverts commit a9c8123c72db47bcab8dd738e8d5256a9ae87f11. --- daemon/file.c | 18 +++--------------- daemon/parted.c | 3 +-- 2 files changed, 4 insertions(+), 17 deletions(-) diff --git a/daemon/file.c b/daemon/file.c index 057e15d..91746e0 100644 --- a/daemon/file.c +++ b/daemon/file.c @@ -525,7 +525,7 @@
2013 May 31
0
Enable bios useserial=yes from command line
...disk path=/var/lib/libvirt/images/"$vmname".qcow2,device=disk,bus=virtio,format=qcow2 --mac= --cpu host --vcpus="$numcpus" --graphics none --noautoconsole --import But cannot seem to find a way to enable bios useserial=yes without issuing a virsh edit $vmname I've tried --extraargs= but that appears to be for kernel command lines, which is not what I want to achieve here. I'm looking for a way to enable serial BIOS from the point the VM is created. The current solution I am using is to do virsh destroy $vmname ; virsh edit $vm_name ; virsh start $vm_name which is not g...
2019 Mar 28
0
[PATCH v2 4/4] OCaml tools: output messages into JSON for machine readable
...nlessHasModule(mod): + if not isModuleInstalled(mod): + return unittest.skip("%s not available" % mod) + return lambda func: func + + +def iterload(stream): + dec = json.JSONDecoder() + for line in stream: + yield dec.raw_decode(line) + + +def loadJsonFromCommand(extraargs): + r, w = os.pipe() + set_fd_inheritable(r) + r = fdopen(r, "r") + set_fd_inheritable(w) + w = fdopen(w, "w") + pid = os.fork() + if pid: + w.close() + l = list(iterload(r)) + l = [o[0] for o in l] + r.close() + return l...
2009 Aug 31
1
Fixed patch...
This version of the patch includes feedback from jboggs at redhat.com, including fixes to the BuildRequires and Requires in the spec file.
2009 Sep 11
1
Text-based node administration tool
This patch obsoletes any previous ones. This is an upstream candidate, so I'm looking for feedback so we can push this and start using it.
2009 Sep 14
1
Bugfixes...
This version fixes a few bugs found by jboggs. It also includes some logging facilities that need to be fleshed out more.
2009 Sep 16
1
Final push candidate for nodeadmin tool...
This patch is ready for pushing upstream.
2009 Sep 16
1
Replacement that includes utils.py
The previous patch was missing this file. Resending.
2019 Mar 28
8
[PATCH v2 0/4] OCaml tools: output messages as JSON machine
Enhance the output in machine parseable mode, by outputting all the messages of OCaml tools as JSON to the machine parseable stream. Related, although not strictly needed for this (and thus can be split if requested), is the addition of the fd format for the machine readable stream. Changes from v1: - use Obj.magic to convert int -> Unix.file_descr - add tests Pino Toscano (4):
2009 Aug 17
13
total warning-removal for daemon/
The warnings in daemon were aggravating and risky for development (too easy to miss new ones) so I spent some time last week and today working on removing them. The first patch gets us down to almost no warnings with the original -Wall setting. That was by far the hardest part. Once I'd done that, I enabled nearly all of gcc's warnings via gnulib's warnings and manywarnings modules
2011 Jun 09
15
[PATCH 00/13] Fix errors found using Coverity static analyzer.
I ran the Coverity static analyzer[1] on libguestfs, and fixed many errors as a result. Coverity found some errors in gnulib, but it doesn't seem to be worth following those up since the version of gnulib we are using is so old. There are a couple more errors (possibly 1 false-positive) which I'm going to send in a separate email. BTW all the errors found by Coverity were in the daemon
2009 Jul 31
2
RFC: This patch is not being submitted for ACK...
...just looking for some feedback on the direction I'm going. The code won't get all the way to the define stage since I'm in the middle of retrofitting it to use virtinst instead of a home spun node definition.
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-
2017 May 04
4
[PATCH 0/3] generator: Allow returned strings to be annotated as devices.
If we want to permit more than 255 drives to be added, then we will have to add the disks to the same virtio-scsi target using different unit (LUN) numbers. Unfortunately SCSI LUN enumeration in the Linux is not deterministic (eg. two disks with target=0, lun=[0,1] can be enumerated as /dev/sda or /dev/sdb randomly). Dealing with that will require some very complex device name translation on the