mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-10-23 16:40:24 +02:00
23168: fix error message for failed bind
This commit is contained in:
parent
2c92d005d7
commit
10f36dd29b
2 changed files with 6 additions and 1 deletions
|
@ -432,7 +432,7 @@ bin_ztcp(char *nam, char **args, Options ops, UNUSED(int func))
|
|||
if (bind(sess->fd, (struct sockaddr *)&sess->sock.in, sizeof(struct sockaddr_in)))
|
||||
{
|
||||
char buf[DIGBUFSIZE];
|
||||
convbase(buf, (zlong)lport, 10);
|
||||
convbase(buf, (zlong)ntohs(lport), 10);
|
||||
zwarnnam(nam, "could not bind to port %s: %e", buf, errno);
|
||||
tcp_close(sess);
|
||||
return 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue