From c48ee0c55593a42a56f1c10f10f439d7a4a0aa81 Mon Sep 17 00:00:00 2001 From: Matteo Cypriani Date: Fri, 13 Sep 2013 11:31:11 -0400 Subject: [PATCH] [UDP-HTTP] "NoResults" instead of "NoResult" Set the explanation to "NoResults" when a request is received but no results were read yet. --- doc/owlps-udp-to-http.t2t | 2 +- owlps-udp-to-http/owlps-udp-to-http.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/owlps-udp-to-http.t2t b/doc/owlps-udp-to-http.t2t index fa5e614..5e2e277 100644 --- a/doc/owlps-udp-to-http.t2t +++ b/doc/owlps-udp-to-http.t2t @@ -49,7 +49,7 @@ The HTTP requests currently implemented are listed bellow. Answer in case of error: ``` Results;NOK;Explanation -``Explanation`` is "NoResult" if no results were received from OwlPS +``Explanation`` is “NoResults” if no results were received from OwlPS Positioner yet. Normal answer: diff --git a/owlps-udp-to-http/owlps-udp-to-http.c b/owlps-udp-to-http/owlps-udp-to-http.c index f4c6f50..b238e7b 100644 --- a/owlps-udp-to-http/owlps-udp-to-http.c +++ b/owlps-udp-to-http/owlps-udp-to-http.c @@ -449,7 +449,7 @@ void prepare_answer(int request_id) if (! results) { - char answer_end[] = ";NOK;NoResult" ; + char answer_end[] = ";NOK;NoResults" ; strncpy(answer + answer_strlen, answer_end, strlen(answer_end)) ; answer_strlen += strlen(answer_end) ; @@ -499,7 +499,7 @@ void prepare_answer(int request_id) if (! results) { - char answer_end[] = ";NOK;NoResult" ; + char answer_end[] = ";NOK;NoResults" ; strncpy(answer + answer_strlen, answer_end, strlen(answer_end)) ; answer_strlen += strlen(answer_end) ;