Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | make rexec support ipv6 |
| 2 | |
Patrick Williams | b9af875 | 2023-01-30 13:28:01 -0600 | [diff] [blame^] | 3 | Upstream-Status: Pending |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 4 | |
| 5 | rexec equals rexec_af(... ,AF_INET) which only support ipv4, |
| 6 | use rexec_af(..., AF_UNSPEC) to support both ipv6 and ipv4. |
| 7 | |
| 8 | Signed-off-by: Roy.Li <rongqing.li@windriver.com> |
| 9 | --- |
| 10 | rexec/rexec.c | 4 ++-- |
| 11 | 1 files changed, 2 insertions(+), 2 deletions(-) |
| 12 | |
| 13 | diff --git a/rexec/rexec.c b/rexec/rexec.c |
| 14 | index 0913c02..9c8f769 100644 |
| 15 | --- a/rexec/rexec.c |
| 16 | +++ b/rexec/rexec.c |
| 17 | @@ -214,8 +214,8 @@ int main(int argc, char *argv[]) |
| 18 | passwd = getpass("Password: "); |
| 19 | } |
| 20 | |
| 21 | - if ( (sock = rexec(&host, port_exec, user_name, passwd, command, |
| 22 | - p_to_aux_sock)) < 0 ) |
| 23 | + if ( (sock = rexec_af(&host, port_exec, user_name, passwd, command, |
| 24 | + p_to_aux_sock, AF_UNSPEC)) < 0 ) |
| 25 | { |
| 26 | fprintf(stderr,"%s: Error in rexec system call: ",argv[0]); |
| 27 | perror(NULL); |
| 28 | -- |
| 29 | 1.7.4.1 |
| 30 | |