mailing list of musl libc
 help / color / mirror / code / Atom feed
From: Rich Felker <dalias@libc.org>
To: musl@lists.openwall.com
Subject: Re: [patch] expose execvpe under _(GNU|BSD)_SOURCE
Date: Sun, 20 Apr 2014 00:29:18 -0400	[thread overview]
Message-ID: <20140420042918.GX26358@brightrain.aerifal.cx> (raw)
In-Reply-To: <CAL3m8eA8L=2pHug_XP7ksHgqd6GEDGiyFQAKdsigEvt70LjbxA@mail.gmail.com>

Committed with minor changes. Thanks.

Rich


On Fri, Apr 18, 2014 at 10:40:28PM -0500, M Farkas-Dyck wrote:
> Forgot to #include "libc.h" last time.
> 
> >From 9740391c7569bfa694cc0de1282858bad9b7f554 Mon Sep 17 00:00:00 2001
> From: M Farkas-Dyck <strake888@gmail.com>
> Date: Tue, 15 Apr 2014 22:02:29 -0500
> Subject: [PATCH] expose execvpe under _(GNU|BSD)_SOURCE
> 
> ---
>  include/unistd.h     | 3 +++
>  src/process/execvp.c | 3 +++
>  2 files changed, 6 insertions(+)
> 
> diff --git a/include/unistd.h b/include/unistd.h
> index bf10a6d..342ab68 100644
> --- a/include/unistd.h
> +++ b/include/unistd.h
> @@ -88,6 +88,9 @@ int execle(const char *, const char *, ...);
>  int execl(const char *, const char *, ...);
>  int execvp(const char *, char *const []);
>  int execlp(const char *, const char *, ...);
> +#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
> +int execvpe(const char *, char *const [], char *const []);
> +#endif
>  int fexecve(int, char *const [], char *const []);
>  _Noreturn void _exit(int);
> 
> diff --git a/src/process/execvp.c b/src/process/execvp.c
> index 0a33e42..7d32200 100644
> --- a/src/process/execvp.c
> +++ b/src/process/execvp.c
> @@ -3,6 +3,7 @@
>  #include <unistd.h>
>  #include <errno.h>
>  #include <limits.h>
> +#include "libc.h"
> 
>  extern char **__environ;
> 
> @@ -47,3 +48,5 @@ int execvp(const char *file, char *const argv[])
>  {
>  	return __execvpe(file, argv, __environ);
>  }
> +
> +weak_alias(__execvpe, execvpe);
> -- 
> 1.8.5.2


  reply	other threads:[~2014-04-20  4:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-19  3:40 M Farkas-Dyck
2014-04-20  4:29 ` Rich Felker [this message]
  -- strict thread matches above, loose matches on Subject: below --
2014-04-16  3:00 M Farkas-Dyck
2014-04-16  3:06 ` Rich Felker
2014-04-16  4:15   ` M Farkas-Dyck
2014-04-16  4:17   ` M Farkas-Dyck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140420042918.GX26358@brightrain.aerifal.cx \
    --to=dalias@libc.org \
    --cc=musl@lists.openwall.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).