about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
Diffstat (limited to 'Src')
-rw-r--r--Src/Modules/tcp.c4
-rw-r--r--Src/Modules/tcp.mdd1
2 files changed, 4 insertions, 1 deletions
diff --git a/Src/Modules/tcp.c b/Src/Modules/tcp.c
index 96dde66e3..58ab8c090 100644
--- a/Src/Modules/tcp.c
+++ b/Src/Modules/tcp.c
@@ -433,7 +433,9 @@ bin_ztcp(char *nam, char **args, Options ops, int func)
 
 	if (bind(sess->fd, (struct sockaddr *)&sess->sock.in, sizeof(struct sockaddr_in)))
 	{
-	    zwarnnam(nam, "could not bind to %s: %e", "0.0.0.0", errno);
+	    char buf[DIGBUFSIZE];
+	    convbase(buf, (zlong)lport, 10);
+	    zwarnnam(nam, "could not bind to port %s: %e", buf, errno);
 	    tcp_close(sess);
 	    return 1;
 	}
diff --git a/Src/Modules/tcp.mdd b/Src/Modules/tcp.mdd
index 041d9138a..88874cd7d 100644
--- a/Src/Modules/tcp.mdd
+++ b/Src/Modules/tcp.mdd
@@ -1,6 +1,7 @@
 name=zsh/net/tcp
 link=dynamic
 load=no
+functions='Functions/TCP/*'
 
 objects="tcp.o"
 autobins="ztcp"