summaryrefslogtreecommitdiff
path: root/util-linux/rdate.c
diff options
context:
space:
mode:
authorEric Andersen2004-01-18 18:18:33 +0000
committerEric Andersen2004-01-18 18:18:33 +0000
commit15eb39c25a03ab8fd0cdfb0d5ec150a1fa053b44 (patch)
tree0660f89eda642263f8b273e590a1bee114985bec /util-linux/rdate.c
parent53766c40639172d4844b9b5a16e692ef379accb2 (diff)
downloadbusybox-15eb39c25a03ab8fd0cdfb0d5ec150a1fa053b44.zip
busybox-15eb39c25a03ab8fd0cdfb0d5ec150a1fa053b44.tar.gz
Stephane Billiart writes:
bb_lookup_port now takes 3 parameters but rdate has not been modified accordingly and fails to compile in the current CVS version. The modification below fixes the problem. Now, RFC868 allows both UDP and TCP implementations of the time protocol so this may not work if someone defines a udp time service other than 37 but who would do that?
Diffstat (limited to 'util-linux/rdate.c')
-rw-r--r--util-linux/rdate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util-linux/rdate.c b/util-linux/rdate.c
index a317cda..a73e8ee 100644
--- a/util-linux/rdate.c
+++ b/util-linux/rdate.c
@@ -51,7 +51,7 @@ static time_t askremotedate(const char *host)
int fd;
bb_lookup_host(&s_in, host);
- s_in.sin_port = bb_lookup_port("time", 37);
+ s_in.sin_port = bb_lookup_port("time", "tcp", 37);
/* Add a timeout for dead or non accessable servers */
alarm(10);