diff options
author | Denis Vlasenko | 2006-09-02 17:53:16 +0000 |
---|---|---|
committer | Denis Vlasenko | 2006-09-02 17:53:16 +0000 |
commit | bcf4908e714644add18fad1614e8b0dea071960d (patch) | |
tree | 83aa66bd5faa69e2eba3391d82018032205ff51b /networking | |
parent | e0b7f71d26d224bd8304d9dfcac3fe9b9d862cd2 (diff) | |
download | busybox-bcf4908e714644add18fad1614e8b0dea071960d.zip busybox-bcf4908e714644add18fad1614e8b0dea071960d.tar.gz |
ping: bind -> xbind
Diffstat (limited to 'networking')
-rw-r--r-- | networking/ping.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/networking/ping.c b/networking/ping.c index 4269eaa..a81472f 100644 --- a/networking/ping.c +++ b/networking/ping.c @@ -330,8 +330,7 @@ static void ping(const char *host) pingsock = create_icmp_socket(); if (sourceaddr.sin_addr.s_addr) { - if (bind(pingsock, (struct sockaddr*)&sourceaddr, sizeof(sourceaddr)) == -1) - bb_error_msg_and_die("could not bind to address"); + xbind(pingsock, (struct sockaddr*)&sourceaddr, sizeof(sourceaddr)); } memset(&pingaddr, 0, sizeof(struct sockaddr_in)); |