Re: [PATCH] Avoid crippled getpass function on Solaris

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ben Walton <bwalton@xxxxxxxxxxxxxxxxxx> writes:

> diff --git a/compat/terminal.h b/compat/terminal.h
> index 97db7cd..8d7b3f9 100644
> --- a/compat/terminal.h
> +++ b/compat/terminal.h
> @@ -3,4 +3,13 @@
>  
>  char *git_terminal_prompt(const char *prompt, int echo);
>  
> +/* getpass() returns at most 8 characters on solaris so use
> +   getpassphrase() which returns up to 256. */
> +# if defined (__SVR4) && defined (__sun) /* solaris */
> +#define GETPASS getpassphrase
> +#else
> +#define GETPASS getpass
> +#endif
> +
> +
>  #endif /* COMPAT_TERMINAL_H */

Wouldn't

	#if solaris
        #define getpass getpassphrase
        #endif

without anything else be more than sufficient?

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]