Current 6.8 git build issues on HP-UX

Darren Tucker dtucker at zip.com.au
Wed Feb 25 09:29:01 AEDT 2015


On Wed, Feb 25, 2015 at 09:20:01AM +1100, Darren Tucker wrote:
[...]
> Sigh.  And now the right patch from the tree that compiled.
> (djm: I get the idea :-)

Tim: is this sufficient to back out the "Work around finicky USL linker"
change?

https://anongit.mindrot.org/openssh.git/commit/?id=d1db656021d0cd8c001a6692f772f1de29b67c8b

> diff --git a/openbsd-compat/bsd-misc.c b/openbsd-compat/bsd-misc.c
> index 65e8003..f7be415 100644
> --- a/openbsd-compat/bsd-misc.c
> +++ b/openbsd-compat/bsd-misc.c
> @@ -31,8 +31,6 @@
>  #include <time.h>
>  #include <unistd.h>
>  
> -#include "xmalloc.h"
> -
>  #ifndef HAVE___PROGNAME
>  char *__progname;
>  #endif
> @@ -43,13 +41,12 @@ char *__progname;
>   */
>  char *ssh_get_progname(char *argv0)
>  {
> +	char *p, *q;
>  #ifdef HAVE___PROGNAME
>  	extern char *__progname;
>  
> -	return xstrdup(__progname);
> +	p = __progname;
>  #else
> -	char *p;
> -
>  	if (argv0 == NULL)
>  		return ("unknown");	/* XXX */
>  	p = strrchr(argv0, '/');
> @@ -57,9 +54,12 @@ char *ssh_get_progname(char *argv0)
>  		p = argv0;
>  	else
>  		p++;
> -
> -	return (xstrdup(p));
>  #endif
> +	if ((q = strdup(p)) == NULL) {
> +		perror("strdup");
> +		exit(1);
> +	}
> +	return q;
>  }
>  
>  #ifndef HAVE_SETLOGIN

-- 
Darren Tucker (dtucker at zip.com.au)
GPG key 8FF4FA69 / D9A3 86E9 7EEE AF4B B2D4  37C9 C982 80C7 8FF4 FA69
    Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.


More information about the openssh-unix-dev mailing list