search for: argptr

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

Did you mean: arg_ptr
2010 Sep 07
0
[LLVMdev] Intrinsic prototype has incorrect number of arguments!
On Sep 7, 2010, at 11:30 AM, F van der Meeren wrote: > > > Any ideas on what I am doing wrong here ? > Why not just use something like: const Type *ArgPtr = Type::getInt8PtrTy(Context); const Type *IntPtr = getTargetData().getIntPtrType(Context); and then: const Type *ArgTypes[3] = {ArgPtr, ArgPtr, IntPtr }; Intrinsic::getDeclaration(TheModule, Intrinsic::memcpy, ArgTypes, 3) to get the type of memcpy? Trying to declare it that way is l...
2003 Jan 14
1
myths about upwards growing stacks
...nd took a look. first thing i found was that the URL for latest version is out of date: klibc is archived at: ftp://ftp.zytor.com/pub/linux/libs/klibc/ the `libs/' is superfluous. more importantly, this piece of code in klibc/arch/README is wrong: #if STACK_GROWS_UP argc = (int)*argptr--; argv = (char **)argptr; envp = argv-(argc+1); #else argc = (int)*argptr++; argv = (char **)argptr; envp = argv+(argc+1); #endif i'm not sure why people think that having an upwards-growing stack means that argc, argv & envp all change places, but they don't. see include/a...
2014 Aug 08
4
[PATCH] for win_utf8_io.c
For better readability the patch is divided by 3 parts. Part #1: for a bit better security replace vsprintf(utmp, format, argptr) with vsnprintf_s(utmp, 32768, _TRUNCATE, format, argptr) Part #2: potential memleak fixed: utf8argv[i] are not freed when utf8argv itself is freed. Part #3: 'if (ret != 0) break;' line seems redundant. -------------- next part -------------- A non-text attachment was scrubbed... N...
2010 Sep 07
2
[LLVMdev] Intrinsic prototype has incorrect number of arguments!
I have created the function prototype with the following code: const uintmax_t methodNameSize = 1024; const char methodNameTemplate[] = "llvm.memcpy.p0i%llu.p0i%llu.i%llu"; char methodName[methodNameSize]; // Create the methodName. memset(methodName, 0, methodNameSize); sprintf(methodName, methodNameTemplate, dstSize, srcSize, lengthSize); // Search for the
2010 Sep 07
2
[LLVMdev] Intrinsic prototype has incorrect number of arguments!
...ernative? Filip On 07 Sep 2010, at 20:37, Eric Christopher wrote: > > On Sep 7, 2010, at 11:30 AM, F van der Meeren wrote: > >> >> >> Any ideas on what I am doing wrong here ? >> > > > Why not just use something like: > > const Type *ArgPtr = Type::getInt8PtrTy(Context); > const Type *IntPtr = getTargetData().getIntPtrType(Context); > > and then: > > const Type *ArgTypes[3] = {ArgPtr, ArgPtr, IntPtr }; > Intrinsic::getDeclaration(TheModule, Intrinsic::memcpy, ArgTypes, 3) > > to get the type of mem...
2014 Aug 08
0
[PATCH] for win_utf8_io.c
...inuing the operation. All conversions are discarded if something failed so not exiting from the loop is wasted effort. On 8.8.2014 18:18, lvqcl wrote: > For better readability the patch is divided by 3 parts. > > Part #1: for a bit better security replace > vsprintf(utmp, format, argptr) > with > vsnprintf_s(utmp, 32768, _TRUNCATE, format, argptr) > > > Part #2: potential memleak fixed: utf8argv[i] are not freed > when utf8argv itself is freed. > > > Part #3: 'if (ret != 0) break;' line seems redundant. > > > ________________________...
2004 Feb 20
1
[patch] fix for "refuse options" ignored due to popt
...DELETE_AFTER, OPT_DELETE_EXCLUDED, OPT_LINK_DEST, OPT_INCLUDE, OPT_INCLUDE_FROM, OPT_MODIFY_WINDOW, - OPT_READ_BATCH, OPT_WRITE_BATCH}; + OPT_READ_BATCH, OPT_WRITE_BATCH, OPT_CHECKSUM, OPT_COMPRESS}; static struct poptOption long_options[] = { /* longName, shortName, argInfo, argPtr, value, descrip, argDesc */ @@ -336,7 +336,7 @@ {"group", 'g', POPT_ARG_NONE, &preserve_gid, 0, 0, 0 }, {"devices", 'D', POPT_ARG_NONE, &preserve_devices, 0, 0, 0 }, {"times", 't', POPT_ARG_NONE,...
2002 Sep 10
0
[PATCH] Add --preserve-atime switch to rsync
...ACKUP_DIR, OPT_IGNORE_ERRORS, OPT_BWLIMIT, OPT_BLOCKING_IO, OPT_NO_BLOCKING_IO, OPT_WHOLE_FILE, OPT_NO_WHOLE_FILE, ! OPT_MODIFY_WINDOW, OPT_READ_BATCH, OPT_WRITE_BATCH, OPT_IGNORE_EXISTING}; static struct poptOption long_options[] = { /* longName, shortName, argInfo, argPtr, value, descrip, argDesc */ --- 289,296 ---- OPT_DELETE_AFTER, OPT_EXISTING, OPT_MAX_DELETE, OPT_BACKUP_DIR, OPT_IGNORE_ERRORS, OPT_BWLIMIT, OPT_BLOCKING_IO, OPT_NO_BLOCKING_IO, OPT_WHOLE_FILE, OPT_NO_WHOLE_FILE, ! OPT_MODIFY_WINDOW, OPT_READ_BATCH, OPT_WRITE_BATCH, O...
2019 Jan 25
0
[klibc:update-dash] [BUILTIN] Small optimisation of command -pv change
...quot;)) != '\0') if (c == 'V') verify |= VERIFY_VERBOSE; else if (c == 'v') verify |= VERIFY_BRIEF; - else if (c == 'p') - path = defpath; #ifdef DEBUG - else + else if (c != 'p') abort(); #endif + else + path = defpath; cmd = *argptr; if (verify && cmd)
2019 Jan 25
0
[klibc:update-dash] [BUILTIN] Use error instead of warnx for fatal errors in printf
....c | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/usr/dash/bltin/printf.c b/usr/dash/bltin/printf.c index b439a3bb..72f89883 100644 --- a/usr/dash/bltin/printf.c +++ b/usr/dash/bltin/printf.c @@ -134,10 +134,8 @@ int printfcmd(int argc, char *argv[]) argv = argptr; format = *argv; - if (!format) { - warnx("usage: printf format [arg ...]"); - goto err; - } + if (!format) + error("usage: printf format [arg ...]"); gargv = ++argv; @@ -192,10 +190,8 @@ pc: fmt += strspn(fmt, SKIP2); ch = *fmt; - if (!ch) { - warnx(...
2019 Jan 25
0
[klibc:update-dash] [BUILTIN] Handle -- in dotcmd
..., 2 deletions(-) diff --git a/usr/dash/main.c b/usr/dash/main.c index 00c5e00d..985e8c4e 100644 --- a/usr/dash/main.c +++ b/usr/dash/main.c @@ -321,15 +321,19 @@ dotcmd(int argc, char **argv) { int status = 0; - if (argc >= 2) { /* That's what SVR2 does */ + nextopt(nullstr); + argv = argptr; + + if (*argv) { char *fullname; - fullname = find_dot_file(argv[1]); + fullname = find_dot_file(*argv); setinputfile(fullname, INPUT_PUSH_FILE); commandname = fullname; status = cmdloop(0); popfile(); } + return status; }
2020 Mar 28
0
[klibc:update-dash] dash: [BUILTIN] Small optimisation of command -pv change
...quot;)) != '\0') if (c == 'V') verify |= VERIFY_VERBOSE; else if (c == 'v') verify |= VERIFY_BRIEF; - else if (c == 'p') - path = defpath; #ifdef DEBUG - else + else if (c != 'p') abort(); #endif + else + path = defpath; cmd = *argptr; if (verify && cmd)
2020 Mar 28
0
[klibc:update-dash] dash: [BUILTIN] Use error instead of warnx for fatal errors in printf
....c | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/usr/dash/bltin/printf.c b/usr/dash/bltin/printf.c index b439a3bb..72f89883 100644 --- a/usr/dash/bltin/printf.c +++ b/usr/dash/bltin/printf.c @@ -134,10 +134,8 @@ int printfcmd(int argc, char *argv[]) argv = argptr; format = *argv; - if (!format) { - warnx("usage: printf format [arg ...]"); - goto err; - } + if (!format) + error("usage: printf format [arg ...]"); gargv = ++argv; @@ -192,10 +190,8 @@ pc: fmt += strspn(fmt, SKIP2); ch = *fmt; - if (!ch) { - warnx(...
2020 Mar 28
0
[klibc:update-dash] dash: [BUILTIN] Handle -- in dotcmd
..., 2 deletions(-) diff --git a/usr/dash/main.c b/usr/dash/main.c index 00c5e00d..985e8c4e 100644 --- a/usr/dash/main.c +++ b/usr/dash/main.c @@ -321,15 +321,19 @@ dotcmd(int argc, char **argv) { int status = 0; - if (argc >= 2) { /* That's what SVR2 does */ + nextopt(nullstr); + argv = argptr; + + if (*argv) { char *fullname; - fullname = find_dot_file(argv[1]); + fullname = find_dot_file(*argv); setinputfile(fullname, INPUT_PUSH_FILE); commandname = fullname; status = cmdloop(0); popfile(); } + return status; }
2020 Mar 28
0
[klibc:update-dash] dash: exec: Never rehash regular built-ins
...--- usr/dash/exec.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/usr/dash/exec.c b/usr/dash/exec.c index 8948754b..6c0a64f6 100644 --- a/usr/dash/exec.c +++ b/usr/dash/exec.c @@ -287,9 +287,11 @@ hashcmd(int argc, char **argv) } c = 0; while ((name = *argptr) != NULL) { - if ((cmdp = cmdlookup(name, 0)) != NULL - && (cmdp->cmdtype == CMDNORMAL - || (cmdp->cmdtype == CMDBUILTIN && builtinloc >= 0))) + if ((cmdp = cmdlookup(name, 0)) && + (cmdp->cmdtype == CMDNORMAL || + (cmdp->cmdtype == CMDBUI...
2013 Jun 03
1
Adding arguments to the options
...on for HTTPS in rsync code like '-v' for "--verbose". But now I want to make that option to take the arguments. For that in options.c file, I have added the entry in the array of structure as, > static struct poptOption long_options[] = { > /* longName, shortName, argInfo, argPtr, value, descrip, argDesc */ > {"xxxx", 'x', xxxxxxx, x, xxxxx, x, x}, > {"https", 'N', POPT_ARG_VAL, &https_port > _s > , 0, 0, 0}} So for getting the value of the argument of option in the https_port_s, I have just added one switch case with...
2002 Jan 29
1
Problems using rsyncd.conf
I am having a lot of troubles setting up an rsync daemon that works properly. I've inspected the Faq-o-matic and as much of the past archives as I can stand, but I can't seem to get any of the solutions suggested there to work. I'm having two problems. First, I can't get password authentication to work. I have ensured that the password file is only readable by root, and that
2019 Jan 25
0
[klibc:update-dash] [BUILTIN] command: allow combining -p with -v
...ile ((c = nextopt("pvV")) != '\0') if (c == 'V') verify |= VERIFY_VERBOSE; else if (c == 'v') verify |= VERIFY_BRIEF; + else if (c == 'p') + path = defpath; #ifdef DEBUG - else if (c != 'p') + else abort(); #endif cmd = *argptr; if (verify && cmd) - return describe_command(out1, cmd, verify - VERIFY_BRIEF); + return describe_command(out1, cmd, path, verify - VERIFY_BRIEF); return 0; }
2020 Mar 28
0
[klibc:update-dash] dash: [BUILTIN] command: allow combining -p with -v
...ile ((c = nextopt("pvV")) != '\0') if (c == 'V') verify |= VERIFY_VERBOSE; else if (c == 'v') verify |= VERIFY_BRIEF; + else if (c == 'p') + path = defpath; #ifdef DEBUG - else if (c != 'p') + else abort(); #endif cmd = *argptr; if (verify && cmd) - return describe_command(out1, cmd, verify - VERIFY_BRIEF); + return describe_command(out1, cmd, path, verify - VERIFY_BRIEF); return 0; }
2002 Mar 08
1
[PATCH][RFC] space saving incrementals
...O_WHOLE_FILE, - OPT_MODIFY_WINDOW, OPT_READ_BATCH, OPT_WRITE_BATCH, OPT_IGNORE_EXISTING}; + OPT_MODIFY_WINDOW, OPT_READ_BATCH, OPT_WRITE_BATCH, OPT_IGNORE_EXISTING, + OPT_COMPARE_PERMS, OPT_LINK_DEST}; static struct poptOption long_options[] = { /* longName, shortName, argInfo, argPtr, value, descrip, argDesc */ @@ -302,6 +308,7 @@ {"no-whole-file", 0, POPT_ARG_NONE, 0, OPT_NO_WHOLE_FILE}, {"copy-unsafe-links", 0, POPT_ARG_NONE, &copy_unsafe_links}, {"perms", 'p', POPT_ARG_NONE, &preserve_perms}, +...