From cd078d5f3ff397437db5c467229d1cada7fb56fb Mon Sep 17 00:00:00 2001 From: Juri Glass Date: Fri, 8 Jul 2011 17:13:30 +0200 Subject: [PATCH] removed SML_SKIP_OPTIONAL from all octet_string parse calls --- sml/src/sml_attention_response.c | 2 +- sml/src/sml_close_request.c | 2 +- sml/src/sml_close_response.c | 2 +- sml/src/sml_get_list_request.c | 8 ++++---- sml/src/sml_get_list_response.c | 6 +++--- sml/src/sml_get_profile_pack_request.c | 6 +++--- sml/src/sml_list.c | 2 +- sml/src/sml_open_request.c | 8 ++++---- sml/src/sml_open_response.c | 4 ++-- 9 files changed, 20 insertions(+), 20 deletions(-) diff --git a/sml/src/sml_attention_response.c b/sml/src/sml_attention_response.c index e3d7e90..b5facbe 100644 --- a/sml/src/sml_attention_response.c +++ b/sml/src/sml_attention_response.c @@ -40,7 +40,7 @@ sml_attention_response *sml_attention_response_parse(sml_buffer *buf){ msg->attention_number = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->attention_message = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->attention_message = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->attention_details = SML_SKIP_OPTIONAL sml_tree_parse(buf); diff --git a/sml/src/sml_close_request.c b/sml/src/sml_close_request.c index a674634..1a64893 100644 --- a/sml/src/sml_close_request.c +++ b/sml/src/sml_close_request.c @@ -49,7 +49,7 @@ sml_close_request * sml_close_request_parse(sml_buffer *buf) { goto error; } - msg->global_signature = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->global_signature = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; return msg; diff --git a/sml/src/sml_close_response.c b/sml/src/sml_close_response.c index c348530..f34690c 100644 --- a/sml/src/sml_close_response.c +++ b/sml/src/sml_close_response.c @@ -35,7 +35,7 @@ sml_close_response *sml_close_response_parse(sml_buffer *buf) { goto error; } - msg->global_signature = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->global_signature = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; return msg; diff --git a/sml/src/sml_get_list_request.c b/sml/src/sml_get_list_request.c index e7ae12e..42fa45e 100644 --- a/sml/src/sml_get_list_request.c +++ b/sml/src/sml_get_list_request.c @@ -70,19 +70,19 @@ sml_get_list_request *sml_get_list_request_parse(sml_buffer *buf) { goto error; } - msg->client_id = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->client_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->server_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->username = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->username = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->password = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->password = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->list_name = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->list_name = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; return msg; diff --git a/sml/src/sml_get_list_response.c b/sml/src/sml_get_list_response.c index 65a332e..bf3dee8 100644 --- a/sml/src/sml_get_list_response.c +++ b/sml/src/sml_get_list_response.c @@ -36,13 +36,13 @@ sml_get_list_response *sml_get_list_response_parse(sml_buffer *buf) { goto error; } - msg->client_id = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->client_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->server_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->list_name = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->list_name = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->act_sensor_time = SML_SKIP_OPTIONAL sml_time_parse(buf); @@ -51,7 +51,7 @@ sml_get_list_response *sml_get_list_response_parse(sml_buffer *buf) { msg->val_list = sml_list_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->list_signature = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->list_signature = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->act_gateway_time = SML_SKIP_OPTIONAL sml_time_parse(buf); diff --git a/sml/src/sml_get_profile_pack_request.c b/sml/src/sml_get_profile_pack_request.c index 631d93f..04a8684 100644 --- a/sml/src/sml_get_profile_pack_request.c +++ b/sml/src/sml_get_profile_pack_request.c @@ -88,13 +88,13 @@ sml_get_profile_pack_request *sml_get_profile_pack_request_parse(sml_buffer *buf printf("TODO:sml_get_profile_pack_request_parse -> not implemented yet"); -/* msg->client_id = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); +/* msg->client_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->server_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->list_name = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->list_name = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; */ /*msg->act_sensor_time = SML_SKIP_OPTIONAL sml_time_parse(buf); @@ -103,7 +103,7 @@ sml_get_profile_pack_request *sml_get_profile_pack_request_parse(sml_buffer *buf msg->val_list = sml_list_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->list_signature = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->list_signature = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->act_gateway_time = SML_SKIP_OPTIONAL sml_time_parse(buf); diff --git a/sml/src/sml_list.c b/sml/src/sml_list.c index 0823302..ac8096b 100644 --- a/sml/src/sml_list.c +++ b/sml/src/sml_list.c @@ -87,7 +87,7 @@ sml_list *sml_list_parse(sml_buffer *buf) { cur->value = SML_SKIP_OPTIONAL sml_value_parse(buf); if (sml_buf_has_errors(buf)) goto error; - cur->value_signature = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + cur->value_signature = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; cur->next = 0; diff --git a/sml/src/sml_open_request.c b/sml/src/sml_open_request.c index f479302..b0748b3 100644 --- a/sml/src/sml_open_request.c +++ b/sml/src/sml_open_request.c @@ -82,7 +82,7 @@ sml_open_request *sml_open_request_parse(sml_buffer *buf) { goto error; } - msg->codepage = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->codepage = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->client_id = sml_octet_string_parse(buf); @@ -91,13 +91,13 @@ sml_open_request *sml_open_request_parse(sml_buffer *buf) { msg->req_file_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->server_id = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->server_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->username = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->username = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->password = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->password = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->sml_version = SML_SKIP_OPTIONAL sml_u8_parse(buf); diff --git a/sml/src/sml_open_response.c b/sml/src/sml_open_response.c index b8c5507..f957c96 100644 --- a/sml/src/sml_open_response.c +++ b/sml/src/sml_open_response.c @@ -35,10 +35,10 @@ sml_open_response *sml_open_response_parse(sml_buffer *buf) { goto error; } - msg->codepage = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->codepage = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; - msg->client_id = SML_SKIP_OPTIONAL sml_octet_string_parse(buf); + msg->client_id = sml_octet_string_parse(buf); if (sml_buf_has_errors(buf)) goto error; msg->req_file_id = sml_octet_string_parse(buf);