X-Git-Url: https://git.teslayout.com/public/public/public/?a=blobdiff_plain;f=source%2Fcomm%2FCompatCodec.cpp;h=4664cbaa12f1c96b0043ea4f4f58948575da7592;hb=c68d53c4623b63ee20014a7eae0b9759a490c90e;hp=1243fb639b5e0b11f29488461f611d347392937e;hpb=4e12ac57e93c052f716a6305ad8fc099c45899d1;p=anna.git diff --git a/source/comm/CompatCodec.cpp b/source/comm/CompatCodec.cpp index 1243fb6..4664cba 100644 --- a/source/comm/CompatCodec.cpp +++ b/source/comm/CompatCodec.cpp @@ -1,8 +1,8 @@ -// ANNA - Anna is Not 'N' Anymore +// ANNA - Anna is Not Nothingness Anymore // // (c) Copyright 2005-2014 Eduardo Ramos Testillano & Francisco Ruiz Rayo // -// https://bitbucket.org/testillano/anna +// http://redmine.teslayout.com/projects/anna-suite // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions @@ -14,7 +14,7 @@ // copyright notice, this list of conditions and the following disclaimer // in the documentation and/or other materials provided with the // distribution. -// * Neither the name of Google Inc. nor the names of its +// * Neither the name of the copyright holder nor the names of its // contributors may be used to endorse or promote products derived from // this software without specific prior written permission. // @@ -120,9 +120,9 @@ throw(RuntimeException) { return result; } -const comm::Variable* comm::CompatCodec::attach(const char* name, const short int id, Integer64& value) +const comm::Variable* comm::CompatCodec::attach(const char* name, const short int id, S64& value) throw(RuntimeException) { - const Integer64 backup(value); + const S64 backup(value); const Variable* result = insert(name, id, a_variables, value); value = backup; return result; @@ -287,7 +287,7 @@ throw(RuntimeException) { register Variable* variable; int stringLen; const char* string; - char aux [sizeof(Integer64)]; + char aux [sizeof(S64)]; if(a_scramble == true) // (1) while(c == 0) c = rand() % 0xff; @@ -317,7 +317,7 @@ throw(RuntimeException) { break; case Variable::Type::Integer64: self += variable->codec(); - self.append(comm::functions::codeInteger64(aux, variable->getInteger64()), sizeof(Integer64)); + self.append(comm::functions::codeInteger64(aux, variable->getInteger64()), sizeof(S64)); break; case Variable::Type::Boolean: self.append(comm::functions::codeShort(aux, variable->getId()), sizeof(short int)); // (3) @@ -440,7 +440,7 @@ throw(RuntimeException) { break; case Variable::Type::Integer64: variable->setValue(comm::functions::decodeInteger64(++ data)); - data += sizeof(Integer64); + data += sizeof(S64); break; case Variable::Type::Boolean: variable->setBoolean((*data & 0x80) ? true : false); @@ -515,7 +515,7 @@ throw(RuntimeException) { break; case Variable::Type::Integer64: variable->setValue(comm::functions::decodeInteger64(++ data)); - data += sizeof(Integer64); + data += sizeof(S64); break; case Variable::Type::Boolean: variable->setBoolean((*data & 0x80) ? true : false);