Skip to content
Snippets Groups Projects
Commit a964e813 authored by Aurelien Jacobs's avatar Aurelien Jacobs
Browse files

use h_addr_list[0] instead of h_addr as this is the posix hostent field name

Originally committed as revision 14768 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 47698b83
No related branches found
No related tags found
No related merge requests found
......@@ -68,7 +68,7 @@ int resolve_host(struct in_addr *sin_addr, const char *hostname)
hp = gethostbyname(hostname);
if (!hp)
return -1;
memcpy(sin_addr, hp->h_addr, sizeof(struct in_addr));
memcpy(sin_addr, hp->h_addr_list[0], sizeof(struct in_addr));
}
return 0;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment