summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThadeu Lima de Souza Cascardo <cascardo@cascardo.eti.br>2015-03-03 06:57:22 -0300
committerThadeu Lima de Souza Cascardo <cascardo@cascardo.eti.br>2015-03-03 09:57:54 -0300
commitb71ce08a6c51261cd24b71b7034477b3e300abd9 (patch)
treed008fd938c894a29be684c828d3b9a3b182257da
parent4fafcd5c3d46b47f088c15bdb155b4870c564ccf (diff)
When encoding message, accept 2015.
-rw-r--r--rnet_encode.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/rnet_encode.c b/rnet_encode.c
index 1a391f2..b653199 100644
--- a/rnet_encode.c
+++ b/rnet_encode.c
@@ -67,7 +67,11 @@ int rnet_encode(struct rnet_decfile *decfile, struct rnet_message **msg)
versao_pgd = strtoul(rnet_decfile_get_header_field(decfile, "nr_versao"), NULL, 10);
ret = strtoul(rnet_decfile_get_header_field(decfile, "in_ret"), NULL, 10);
- if (!strcmp(exerc, "2014")) {
+ if (!strcmp(exerc, "2015")) {
+ header_size = RNET_HEADER_SIZE_2015;
+ header_head = RNET_HEADER_HEAD_2015;
+ header_tail = RNET_HEADER_TAIL_2015;
+ } else if (!strcmp(exerc, "2014")) {
header_size = RNET_HEADER_SIZE_2014;
header_head = RNET_HEADER_HEAD_2014;
header_tail = RNET_HEADER_TAIL_2014;