Hoping for some guidance. I am trying to create a log record to save into a file for an assignment.
The first line of the code works with no problem. The second line of code is throwing an error:
proj4.c:188: warning: passing argument 2 of 'strcpy' makes pointer from integer without a cast
I'm not certain I understand why. Isn't inet_ntoa returning a char pointer? Why can't I copy that to the log? Log is declared as char log
char *inet_ntoa(struct in_addr in); <---returns a char *?
Code:printf("IP of requestor %s\n", inet_ntoa(remote.sin_addr)); strcpy(log, inet_ntoa(remote.sin_addr));