[UDP-HTTP] Stop using OWLPS_DEBUG
This commit is contained in:
parent
e114a6997a
commit
ca918af0ab
|
@ -79,6 +79,9 @@
|
||||||
|
|
||||||
char *program_name = NULL ;
|
char *program_name = NULL ;
|
||||||
|
|
||||||
|
// This needs to become an option when we introduce options
|
||||||
|
#define verbose true
|
||||||
|
|
||||||
results_list *results = NULL ;
|
results_list *results = NULL ;
|
||||||
unsigned int nb_results = 0 ;
|
unsigned int nb_results = 0 ;
|
||||||
sem_t lock_results ;
|
sem_t lock_results ;
|
||||||
|
@ -329,18 +332,16 @@ void* tcp_server(void *NULL_value)
|
||||||
}
|
}
|
||||||
client_message[nbytes] = '\0' ;
|
client_message[nbytes] = '\0' ;
|
||||||
|
|
||||||
#ifdef OWLPS_DEBUG
|
if (verbose)
|
||||||
printf("Got a message from the client:\n"
|
printf("Got a message from the client:\n"
|
||||||
"\"%s\"\n", client_message) ;
|
"\"%s\"\n", client_message) ;
|
||||||
#endif // OWLPS_DEBUG
|
|
||||||
|
|
||||||
request_id =
|
request_id =
|
||||||
extract_request_from_message(client_request, client_message) ;
|
extract_request_from_message(client_request, client_message) ;
|
||||||
prepare_answer(request_id) ;
|
prepare_answer(request_id) ;
|
||||||
|
|
||||||
#ifdef OWLPS_DEBUG
|
if (verbose)
|
||||||
printf("Answer to send:\n\"%s\"\n", answer) ;
|
printf("Answer to send:\n\"%s\"\n", answer) ;
|
||||||
#endif // OWLPS_DEBUG
|
|
||||||
|
|
||||||
/* Send the answer */
|
/* Send the answer */
|
||||||
nbytes = send(newsockfd, answer, answer_strlen, 0) ;
|
nbytes = send(newsockfd, answer, answer_strlen, 0) ;
|
||||||
|
|
Loading…
Reference in New Issue