search for: pname

Displaying 20 results from an estimated 68 matches for "pname".

Did you mean: name
2003 Oct 30
1
Patch to make sshd work on multihomed systems
...,7 @@ #include "xmalloc.h" #include "bufaux.h" +#include "canohost.h" #include "compat.h" #include "log.h" #include "monitor_wrap.h" @@ -226,9 +227,18 @@ OM_uint32 status; char lname[MAXHOSTNAMELEN]; gss_OID_set oidset; + char *pname; gss_create_empty_oid_set(&status, &oidset); gss_add_oid_set_member(&status, ctx->oid, &oidset); + + pname = get_local_name(packet_get_connection_in()); + if (pname) { + strlcpy(lname, pname, MAXHOSTNAMELEN); + xfree(pname); + } else if (gethostname(lname, MAXHOSTNAMELEN))...
2018 Apr 06
1
[nbdkit PATCH] python: Let zero's may_trim parameter be optional
...))) { + char *str = PyString_AsString(elt); + if (str && !strcmp(str, name)) + return 1; + } + return 0; +} + +/* Does a callback support the given keyword parameter? */ +static int +callback_has_parameter (PyObject *fn, const char *name) +{ + int r = 0; + PyObject *inspect, *pname, *spec, *args; + + assert (script != NULL); + assert (module != NULL); + + pname = PyString_FromString ("inspect"); + if (!pname) + return -1; + inspect = PyImport_Import (pname); + Py_DECREF (pname); + + if (!inspect) + return -1; + +#if PY_MAJOR_VERSION >= 3 + pname = P...
2010 Feb 02
2
character variables in substitute()
...to be the Greek beta and, possibly, R in italics (like one would get in an explicit expression. The reason for this is that I want to write a string builder function that takes vectors of variable names and their values and return a plotmath expression for labeling a plot. One approach I tried is pname = c("R","beta") params = c(6,15) substitute(p == v,list(p = pname[i],v = format(params[i],digits=4)) but this just copies the character strings in pname into the expression. Can anyone help me do what I want? How would I manage passing the resulting string back to the calling r...
2018 Apr 11
0
[nbdkit PATCH v2 1/5] python: Let zero's may_trim parameter be optional
...) { + char *str = PyString_AsString (elt); + if (str && !strcmp (str, name)) + return 1; + } + return 0; +} + +/* Does a callback support the given keyword parameter? */ +static int +callback_has_parameter (PyObject *fn, const char *name) +{ + int r = 0; + PyObject *inspect, *pname, *spec, *args; + + assert (script != NULL); + assert (module != NULL); + +#ifdef HAVE_PYSTRING_FROMSTRING + pname = PyString_FromString ("inspect"); +#else + pname = PyUnicode_FromString ("inspect"); +#endif + if (!pname) + return -1; + inspect = PyImport_Import (pname)...
2006 Jun 03
3
More on bug 7924
...(x->sxpinfo.named) = v; $1 = 0x85cfd8 $2 = {sxpinfo = {type = 13, obj = 0, named = 2, gp = 0, mark = 1, debug = 0, trace = 0, fin = 0, gcgen = 0, gccls = 1}, attrib = 0x508818, gengc_next_node = 0x6db278, gengc_prev_node = 0x8442b8, u = {primsxp = { offset = 2}, symsxp = {pname = 0x2, value = 0x230002acc2, internal = 0x21000090}, listsxp = {carval = 0x2, cdrval = 0x230002acc2, tagval = 0x21000090}, envsxp = {frame = 0x2, enclos = 0x230002acc2, hashtab = 0x21000090}, closxp = {formals = 0x2, body = 0x230002acc2, env = 0x21000090}, promsxp...
2003 Apr 07
0
Fwd: [VulnWatch] [DDI-1013] Buffer Overflow in Samba allows remote root compromise
...r a Windows NT > domain > controller. > > >o Problem description: > An anonymous user can gain remote root access due to a buffer overflow > caused > by a StrnCpy() into a char array (fname) using a non-constant length > (namelen). > > StrnCpy(fname,pname,namelen); /* Line 252 of smbd/trans2.c */ > > In the call_trans2open function in trans2.c, the Samba StrnCpy function > copies pname into fname using namelen. The variable namelen is > assigned the > value of strlen(pname)+1, which causes the overflow. > > The v...
2008 Dec 03
1
nlminb: names of parameter vector not passed to objective function
...L-BFGS-B") ## --> works without problems ## 3) THE PROBLEM nlminb(start, hdev, lower = 0.001, upper = Inf) ## --> $objective is NA because names of "start" are not passed through ## 4) workaround ------------------------------------------------------- hdev <- function(par, pnames) { names(par) <- pnames -sum(dnbinom(x, mu = par["mu"], size = par["size"], log = TRUE)) } nlminb(start, hdev, pnames = names(start), lower = 0.001, upper = Inf) ## --> works, but is it possible to improve nlminb ## so that the workaround can be avoided ?...
2020 Oct 29
2
[External] Something is wrong with the unserialize function
...ltrep.c =================================================================== --- src/main/altrep.c (revision 79385) +++ src/main/altrep.c (working copy) @@ -275,10 +275,11 @@ SEXP psym = ALTREP_SERIALIZED_CLASS_PKGSYM(info); SEXP class = LookupClass(csym, psym); if (class == NULL) { - SEXP pname = ScalarString(PRINTNAME(psym)); + SEXP pname = PROTECT(ScalarString(PRINTNAME(psym))); R_tryCatchError(find_namespace, pname, handle_namespace_error, NULL); class = LookupClass(csym, psym); + UNPROTECT(1); } return class; } seems to remove the warning; I'm...
2003 Feb 07
0
confint.lm in MASS
...intervals are computed for all parameters anyway, and then assigned to a matrix which is too small for all of them (see function body below). As I said, I think it's worth knowing it. Best, Giovanni > confint.lm function (object, parm, level = 0.95, ...) { cf <- coef(object) pnames <- names(cf) if (missing(parm)) parm <- seq(along = pnames) else if (is.character(parm)) parm <- match(parm, pnames, nomatch = 0) a <- (1 - level)/2 a <- c(a, 1 - a) pct <- paste(round(100 * a, 1), "%") ci <- array(NA, dim =...
2002 Oct 04
1
gnls from library nlme
Dear all, I am trying to gain some experience with the function gnls from the nlme package. I tried to model the Theophyline data by trying to model the presumed dependency of the clearance on the body weight. This is my function call of gnls: gnls(conc~SSfol(Dose,Time,lKe,lKa,lCl),data=Theoph, params=list(lKe~1,lKa~1,lCl~Wt),start=c(-2.4,0.46,-3.22,0.01)) That's been the result: Error
2008 Dec 19
0
"parm" argument in confint.multinom () nnet package
...r-project.org/plugins/scmsvn/viewcvs.php/*checkout*/pkg/R/utilities.R?rev=2&root=rcmdr>). However, with a few minor changes, the function in the nnet package could work as I had expected it to: confint.mult<-function (object, parm, level = 0.95, ...) { cf <- coef(object) pnames <- if (is.matrix(cf)) colnames(cf) else names(cf) if (missing(parm)) parm <- seq_along(pnames) else if (is.character(parm)) parm <- match(parm, pnames, nomatch = 0) a <- (1 - level)/2 a <- c(a, 1 - a) pct <- paste(round(...
2004 May 04
2
Seeing the definition of a function
Dear all, I was trying to see how the function 'confint' is defined. Doing > confint function (object, parm, level = 0.95, ...) UseMethod("confint") <environment: namespace:stats> does not really enlighten me. How can I get to see the implementation (I guess it should be possible according to the general philosophy of the R project)? Thanks in advance S??ren
2019 Apr 30
2
mccollect with NULL in R 3.6
Dear All, I'm running into issues with calling mccollect on a list containing NULL using R 3.6 (this used to work in 3.5.3): jobs <- lapply( list(NULL, 'foobar'), function(x) mcparallel(identity(x))) mccollect(jobs, wait = FALSE, timeout = 0) #> Error in names(res) <- pnames[match(s, pids)] : #> 'names' attribute [2] must be the same length as the vector [1] Note, setting a "name" for the jobs does not help, but the above works with "wait=TRUE", and also if I change the order of NULL and "foobar", although in that case, the...
2006 Jun 23
1
How to use mle or similar with integrate?
Hi I have the following formula (I hope it is clear - if no, I can try to do better the next time) h(x, a, b) = integral(0 to pi/2) ( ( integral(D/sin(alpha) to Inf) ( ( f(x, a, b) ) dx ) dalpha ) and I want to do an mle with it. I know how to use mle() and I also know about integrate(). My problem is to give the parameter values a and b to the
2010 Feb 01
0
Building a plotmath string in a function
...am getting nowhere. Could someone point me to some references beyond the standard documentation that might help. Here's my latest attempt: BuildParString = function(params) { nPar = length(params) # params is a vector of numerical values s = NULL if(nPar < 1) { return } pNames = c("R","P[m]","k[a]","alpha[r]","beta[r]","phi") vparams = format(params,digits=3) s = as.expression(substitute(pp==vv,list(vv=vparams[1],pp=pNames[1]))) for(i in 2:nPar) { s = c(s,eval(as.expression(substitute(expression(pp==vv...
2011 Mar 01
1
more boa plots questions
...boa.chain.add(boa.importMatrix('B'), 'B') #plot trace plot problems arise here! I know I can get trace plots using boa.plot('trace') but this plots the parameter chains on the same plot- I want separate plots using boa.plot.trace() #from the manual.. boa.plot.trace(lnames, pname, annotate = boa.par("legend")) lnames: Character vector giving the name of the desired MCMC sequence in the working session list of sequences. pname: Character string giving the name of the parameters to be plotted. annotate: Logical value indicating that a legend be...
2003 Feb 02
1
Winspool errors with notepad
When I run notepad or sthing that needs winspool I get : err:winspool:AddPrinterW pName = L"" - unsupported err:winspool:PRINTCAP_ParseEntry lp not added by AddPrinterA (87) What should I do fix it ? The docu didnt help about this. (Perhaps it should be updated, as the psdrv.reg doesnt exist anymore.) [syl@snoop Temp]$ notepad --debugmsg +winspool trace:winspool:AddPrinter...
2008 Apr 22
1
HeapAlloc vs. malloc. How does HeapAlloc work?
...r = NULL; ??? include_defs[num_include_def].nrofentries = 0; Nobody is checking NULL value of include_defs and later there is strcpy() with HeapAlloc as parameter. In dlls/winspool.drv/info.c function 'static LPDEVMODEA DEVMODEdupWtoA(HANDLE heap, const DEVMODEW *dmW)' line 1709 ???? if (pName) { ???????? len = MultiByteToWideChar(CP_ACP, 0, pName, -1, NULL, 0); ??????? nameW = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); ???????? MultiByteToWideChar(CP_ACP, 0, pName, -1, nameW, len); ???? } Again nobody is checking the nameW value. Maybe it is checked inside 'MultiByteToWid...
2002 Jul 24
0
enumerating shared printers to the print browse master
...IPX: NetBIOS Packet - 6112.08003E3046DE.455 -&gt; 6112.02608C3F3E55.455 - 0 Hops NBIPX: Session Data SMB: C transact TransactNmPipe, FID = 0x200c MSRPC: c/o RPC Request: call 0x1 opnum 0x5 context 0x0 hint 0x11C R_WINSPOOL: RPC Client call winspool:RpcAddPrinter(..) R_WINSPOOL: STRING_HANDLE pName = \\NTSERVER R_WINSPOOL: PPRINTER_CONTAINER pPrinterContainer {..} R_WINSPOOL: DWORD Level = 1 (0x1) R_WINSPOOL: (Untyped 1) PrinterInfo {..} R_WINSPOOL: Switch Value = 1 (0x1) R_WINSPOOL: LPPRINTER_INFO_1W pPrinterInfo1 {..} R_WINSPOOL: DWORD Flags = 24 (0x18) R_WINSPOOL: LPWSTR pDescription = 357...
2005 Jun 29
1
Viewing R objects in gdb
...is exactly what an example in the R Extensions manual section 4.11.2 "Inspecting R objects when debugging" does, but the code there doesn't work, presumably because the R internals have changed since it was written. Specifically, I get (gdb) p $a->u.listsxp.tagval->u.symsxp.pname->u.vecsxp.type.c Error: There is no member named vecsxp. where $a was set to be the attrib member of an SEXP. Could someone let me know what needs to be fixed for this to work? I imagine it's a typecast, but I haven't been able to put it together. (An example using R_PV to print the...