search for: execlp

Displaying 20 results from an estimated 57 matches for "execlp".

2013 Oct 17
4
Notes on getting libguestfs to work on Mac OS X
...mp;xdr, ret, 0)) - src/launch-direct.c: comment out - if (qemu_supports (g, data, "-nodefaults")) ADD_CMDLINE ("-nodefaults"); [This works around a qemu bug: qemu: qemu_mutex_lock: Invalid argument when using the -nodefaults parameter] - fuse/guestunmount.c: replace execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); -> execlp ("/sbin/umount", "fusermount", mountpoint, NULL); - fuse/guestunmount.c: replace execlp ("/sbin/fuser", "fuser", "-v", "-m&quo...
2013 May 03
1
Race condition in lightdm greeter setup
...on Launchpad with more details (https://bugs.launchpad.net/lightdm/+bug/1172752), but to work on a proper fix, ideas on how to fix this would be welcome. During greeter setup "lightdm --session-child" is spawned twice. The first call to session_start() that does fork+execlp() is done from greeter_start() and right after that handle_login() calls session_stop() + session_start(). session_stop() sends SIGTERM to the child process, but if the child has not managed to call execlp() yet, it still has signal handler set for SIGTERM, because fork copies the parent''s...
2015 Feb 05
4
Patchable build problems on OS X 10.10
Hello, I'm attempting to create a Homebrew formula to get libguestfs to compile on Mac OS X. I've managed to achieve success with several monkey patches, but since Homebrew's policy is to contact maintainers about proper fixes in upstream, I would like to ask if there are any plans to fix these issues. I'm afraid I don't know C well enough to propose decent solutions myself.
2013 Oct 17
2
Re: Notes on getting libguestfs to work on Mac OS X
...- if (xdrp && ret && !xdrp (&xdr, ret)) -> if (xdrp && ret && !xdrp (&xdr, ret, 0)) - src/launch-direct.c: comment out - if (qemu_supports (g, data, "-nodefaults")) ADD_CMDLINE ("-nodefaults"); - fuse/guestunmount.c: replace - execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); -> execlp ("/sbin/umount", "fusermount", mountpoint, NULL); - fuse/guestunmount.c: replace - execlp ("/sbin/fuser", "fuser", "-v", "-m&qu...
2015 Feb 09
5
Re: Patchable build problems on OS X 10.10
...> > +++ fuse/guestunmount.c > > @@ -257,7 +257,7 @@ do_fusermount (const char *mountpoint, char **error_rtn) > > /* We have to parse error messages from fusermount, so ... */ > > setenv ("LC_ALL", "C", 1); > > > > - execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); > > + execlp ("/sbin/umount", "umount", mountpoint, NULL); > > fusermount is needed on Linux, so this is an example of a patch > which could be written instead as: >...
2015 Feb 09
0
[PATCH 5/5] macosx/bsd: Alternatives for linux-specific commands
...4 --- a/fuse/guestunmount.c +++ b/fuse/guestunmount.c @@ -257,7 +257,12 @@ do_fusermount (const char *mountpoint, char **error_rtn) /* We have to parse error messages from fusermount, so ... */ setenv ("LC_ALL", "C", 1); +#ifdef __linux__ execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); +#else + /* use umount where fusermount is not available */ + execlp ("umount", "umount", mountpoint, NULL); +#endif perror ("exec"); _exit (EXIT_FAILURE); }...
2015 Feb 13
1
[PATCH] fuse: Alternatives for Linux-specific commands
...4 --- a/fuse/guestunmount.c +++ b/fuse/guestunmount.c @@ -257,7 +257,12 @@ do_fusermount (const char *mountpoint, char **error_rtn) /* We have to parse error messages from fusermount, so ... */ setenv ("LC_ALL", "C", 1); +#ifdef __linux__ execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); +#else + /* use umount where fusermount is not available */ + execlp ("umount", "umount", mountpoint, NULL); +#endif perror ("exec"); _exit (EXIT_FAILURE); }...
2015 Feb 06
0
Re: Patchable build problems on OS X 10.10
...t; --- fuse/guestunmount.c > +++ fuse/guestunmount.c > @@ -257,7 +257,7 @@ do_fusermount (const char *mountpoint, char **error_rtn) > /* We have to parse error messages from fusermount, so ... */ > setenv ("LC_ALL", "C", 1); > > - execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); > + execlp ("/sbin/umount", "umount", mountpoint, NULL); fusermount is needed on Linux, so this is an example of a patch which could be written instead as: #if !(defined __APPLE...
2015 Feb 09
11
[PATCH 1/5] macosx: Add required third parameter for xdrproc_t callbacks
>From Apple's xdr.h: "If your code invokes an xdrproc_t callback, it must be modified to pass a third parameter, which may simply be zero." --- src/proto.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/proto.c b/src/proto.c index 92ae84d..57f4882 100644 --- a/src/proto.c +++ b/src/proto.c @@ -252,7 +252,12 @@
2006 May 16
2
Multiple Registers
List, Does anyone know how to limit the amount of registrations that a sip user can have? For example, I have 2 softphones that I use on my laptop & desktop, both use the same username & password. If I have both softphones up at the same time, I can make simultaneous calls with each of them. I know you can have call-limit=1 but in this case, I want to allow them to have 3 way calling
2016 May 19
0
[PATCH 2/3] tests: remove remaining relative paths to binaries
...7;test-guestunmount-fd.c b/fuse/test-guestunmount-fd.c index ad7ff74..019f821 100644 --- a/fuse/test-guestunmount-fd.c +++ b/fuse/test-guestunmount-fd.c @@ -70,7 +70,7 @@ main (int argc, char *argv[]) snprintf (fd_str, sizeof fd_str, "%d", pipefd[0]); - execlp ("./guestunmount", "guestunmount", "--fd", fd_str, "/", NULL); + execlp ("guestunmount", "guestunmount", "--fd", fd_str, "/", NULL); perror ("execlp"); _exit (EXIT_FAILURE); } diff...
2015 Feb 09
0
Re: Patchable build problems on OS X 10.10
On 9 February 2015 at 09:56, Pino Toscano <ptoscano@redhat.com> wrote: > On Friday 06 February 2015 10:03:37 Richard W.M. Jones wrote: [...] >> #if !(defined __APPLE__ && defined __MACH__) >> execlp ("fusermount", "fusermount", "-u", mountpoint, NULL); >> #else >> execlp ("/sbin/umount", "umount", mountpoint, NULL); >> #endif > > Or rather use fusermount only on Linux and umount (with no path) > else...
2007 Aug 15
0
[git patch] fstype support + minor stuff
...sprintf.o \ - asprintf.o vasprintf.o \ - vsscanf.o sscanf.o ctypes.o \ - strntoumax.o strntoimax.o \ - atoi.o atol.o atoll.o \ - strtol.o strtoll.o strtoul.o strtoull.o \ - strtoimax.o strtoumax.o \ - globals.o exit.o atexit.o onexit.o \ - execl.o execle.o execv.o execvpe.o execvp.o execlp.o execlpe.o \ - fork.o vfork.o wait.o wait3.o waitpid.o system.o \ - setpgrp.o getpgrp.o daemon.o \ - printf.o vprintf.o fprintf.o vfprintf.o perror.o \ - statfs.o fstatfs.o umount.o \ - creat.o open.o openat.o open_cloexec.o \ - fopen.o fread.o fread2.o fgetc.o fgets.o \ - fwrite.o f...
2016 Mar 18
9
[PATCH 0/7] Small portability changes
Assorted collection of small improvements in making libguestfs build on non-Linux OSes; most of the changes impact tests though. Thanks, Pino Toscano (7): build: check the path of fuser, and use it in FUSE code tests: move guestfs-md5.sh to test-data v2v: tests: isolate SHA1 calculation in an own shared function v2v: tests: use guestfs-hashsums.sh for MD5 php: pass $(MAKE) to
2013 Apr 20
3
[Bug 2094] New: Executing commands via ssh on a remote host has different parameter passing properties
...ratt.net Consider the file /tmp/ap.sh which simply prints out all the arguments to it: #! /bin/sh while [ $# -ge 1 ]; do echo "arg: $1" shift done If I create a C file ex_local.c: #include <unistd.h> int main(int argc, char** argv) { execlp(argv[1], argv[1], "a", "a'b", NULL); return 0; } and then compile and run it, the arguments passed to it are printed out: $ ex_local /tmp/ap.sh a a'b $ which is correct. If I have this C file ex_ssh.c: #include <unistd.h> int main(i...
2017 Feb 03
5
[PATCH 0/5] Support socket activation in virt-p2v.
As the subject says, support socket activation in virt-p2v. I have added upstream support for socket activation to nbdkit already: https://github.com/libguestfs/nbdkit/commit/7ff39d028c6359f5c0925ed2cf4a2c4c751af2e4 I posted a patch for qemu-nbd, still waiting on more reviews for that one: https://www.mail-archive.com/qemu-devel@nongnu.org/msg427246.html
2019 Oct 01
2
Re: [PATCH libnbd v2 2/2] api: Implement local command with systemd socket activation.
...; + set_error (ENOTSUP, "platform does not support socket activation"); > + return 0; > +#endif We probably ought to add a matching nbd_supports_socket_activation() feature function. Or, it would be possible to create a fallback for execvpe() on platforms that lack it by using execlpe() and our own path-walker utility function. Can be done as a followup patch. If we do that, then the mere presence of LIBNBD_HAVE_NBD_CONNECT_SA is witness enough of the functionality, rather than needing a runtime probe. > +++ b/lib/connect.c > + > +int > +nbd_unlocked...
2019 Nov 15
1
Re: [PATCH libnbd v2 2/2] api: Implement local command with systemd socket activation.
...tivation"); >>> + return 0; >>> +#endif >> >> We probably ought to add a matching nbd_supports_socket_activation() >> feature function. >> >> Or, it would be possible to create a fallback for execvpe() on >> platforms that lack it by using execlpe() and our own path-walker >> utility function. Can be done as a followup patch. If we do that, >> then the mere presence of LIBNBD_HAVE_NBD_CONNECT_SA is witness >> enough of the functionality, rather than needing a runtime probe. > > I'm hoping we will find the time...
2015 Feb 02
8
[PATCH 0/7 v2] Make copy_in & copy_out APIs, and use copy_in in customize
Hi, attached there is the second version of the patch series adding copy_in and copy_out in the library, mostly moving them from guestfish. It also adds the copy_in usage in virt-customize, as aid in a new image building. Thanks, Pino Toscano (7): cmd: add a way to run (and wait) asynchronously commands cmd: add a child-setup callback cmd: add the possibility to get a fd to the process
2000 Sep 09
0
2.2.0p1 PATCH: ssh/scp/slogin will invoke ssh-askpass
...t; 0) + fatal("ssh_askpass: pipe: %s", strerror(errno)); + if ((pid = fork()) < 0) + fatal("ssh_askpass: fork: %s", strerror(errno)); + if (pid == 0) { + close(p[0]); + if (dup2(p[1], STDOUT_FILENO) < 0) + fatal("ssh_askpass: dup2: %s", strerror(errno)); + execlp(askpass, askpass, msg, (char *) 0); + fatal("ssh_askpass: exec(%s): %s", askpass, strerror(errno)); + } + close(p[1]); + len = read(p[0], buf, sizeof buf); + close(p[0]); + while (waitpid(pid, &status, 0) < 0) + if (errno != EINTR) + break; + if (len <= 1) + return xstrdup(...