gbowne1 / random_c_cpp_programs

A collection of my random opensource C and C++ programs
MIT License
3 stars 6 forks source link

Missing `h_addr` in fingerclient.c #41

Open gbowne1 opened 3 months ago

gbowne1 commented 3 months ago

For some reason, h_addr is missing.

gbowne1 commented 1 month ago

$ gcc -Wall -Wextra -pedantic -std=c99 -O2 fingerclient.c -o ../build/fingerclient fingerclient.c: In function ‘main’: fingerclient.c:52:46: error: ‘struct hostent’ has no member named ‘h_addr’ memcpy(&serv_addr.sin_addr.s_addr, server->h_addr, server->h_length); ^~