由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Unix版 - help! cannot bind to socket!
相关主题
Is it possible to bind several sockets to 1 port?question about the set up directory
socket 编程求救。。。Re: how to close port/socket from parent process?help!!!!!!!!!
a difficult question请问非root用户在openBSD上可以用ports安装软件吗?
怎样使UNIX下homepage目录下的内容文件的LINK到底有什么用处?
[转载] how to unbind a socket?Question about linking two directories
a socket question编译问题
哪位大虾给偶讲讲socket?FTP Help
I am crazy about this!!Is there any software can D/L a whole directory?
相关话题的讨论汇总
话题: bind话题: socket话题: port话题: cannot话题: system
进入Unix版参与讨论
1 (共1页)
w********r
发帖数: 6
1
look at the code.
I compare it with the example program words by words.
and I have tried -lsocket -lsnl in linking.
(of course, the system says there is no such file or directory.
BTW, all the socket and bind are system calles. need to link
socket library?)
does not work at all.
I typed the error message, it says: the address is already
in use.
following is the code. thanks a lot!!
m*****e
发帖数: 4193
2
So the answer is very clear: address is already in use. Try to bind a free
port.

【在 w********r 的大作中提到】
: look at the code.
: I compare it with the example program words by words.
: and I have tried -lsocket -lsnl in linking.
: (of course, the system says there is no such file or directory.
: BTW, all the socket and bind are system calles. need to link
: socket library?)
: does not work at all.
: I typed the error message, it says: the address is already
: in use.
: following is the code. thanks a lot!!

w********r
发帖数: 6
3
rhe port is not used. I have changed the
HTTPD port to 81 already
I still can not use 80??

【在 m*****e 的大作中提到】
: So the answer is very clear: address is already in use. Try to bind a free
: port.

s********k
发帖数: 107
4
Try 4000. 80 is used for system, usually is http.

【在 w********r 的大作中提到】
: rhe port is not used. I have changed the
: HTTPD port to 81 already
: I still can not use 80??

m*****e
发帖数: 4193
5
try telnet to that port you are trying to bind, and see whether you get
a Connection refused error.

【在 w********r 的大作中提到】
: rhe port is not used. I have changed the
: HTTPD port to 81 already
: I still can not use 80??

w********r
发帖数: 6
6
I tried.
error msg:
Could not open a connection to host on port 80 :
Connect failed
whatis the meaning? the port is not in used at all, right?

【在 m*****e 的大作中提到】
: try telnet to that port you are trying to bind, and see whether you get
: a Connection refused error.

1 (共1页)
进入Unix版参与讨论
相关主题
Is there any software can D/L a whole directory?[转载] how to unbind a socket?
A simple question!a socket question
[转载] 问一个问题哪位大虾给偶讲讲socket?
gcc in mac OSXI am crazy about this!!
Is it possible to bind several sockets to 1 port?question about the set up directory
socket 编程求救。。。Re: how to close port/socket from parent process?help!!!!!!!!!
a difficult question请问非root用户在openBSD上可以用ports安装软件吗?
怎样使UNIX下homepage目录下的内容文件的LINK到底有什么用处?
相关话题的讨论汇总
话题: bind话题: socket话题: port话题: cannot话题: system