replacing func() with xfunc() where appropriate

This commit is contained in:
Denis Vlasenko
2006-09-03 12:21:59 +00:00
parent 87d80dcc3e
commit 27af5a0dd3
6 changed files with 12 additions and 21 deletions

View File

@@ -259,7 +259,7 @@ int arping_main(int argc, char **argv)
char *source = NULL;
char *target;
s = socket(PF_PACKET, SOCK_DGRAM, 0);
s = xsocket(PF_PACKET, SOCK_DGRAM, 0);
ifindex = errno;
// Drop suid root privileges
@@ -346,11 +346,8 @@ int arping_main(int argc, char **argv)
if (!(cfg&dad) || src.s_addr) {
struct sockaddr_in saddr;
int probe_fd = socket(AF_INET, SOCK_DGRAM, 0); /* maybe use bb_xsocket? */
int probe_fd = xsocket(AF_INET, SOCK_DGRAM, 0);
if (probe_fd < 0) {
bb_error_msg_and_die("socket");
}
if (device) {
if (setsockopt
(probe_fd, SOL_SOCKET, SO_BINDTODEVICE, device,