Forráskód Böngészése

completely fixing UA_QualifiedName: removing 'reserved' field
+additions to .gitignore

Stasik0 10 éve
szülő
commit
54f21007cb
3 módosított fájl, 8 hozzáadás és 4 törlés
  1. 4 0
      .gitignore
  2. 1 1
      include/ua_basictypes.h
  3. 3 3
      src/ua_basictypes.c

+ 4 - 0
.gitignore

@@ -16,6 +16,7 @@
 *.pyc
 *.gcno
 *.gcda
+.dirstamp
 /bin
 m4
 /autom4te.cache
@@ -37,6 +38,9 @@ config.log
 /configure
 /missing
 /html
+/doc/html/*
+/doc/Doxyfile
+/doc/doxyfile.stamp
 *~
 GIT_REVISION
 SVN_REVISION

+ 1 - 1
include/ua_basictypes.h

@@ -363,7 +363,7 @@ enum UA_ExtensionObject_EncodingMaskType_enum {
 /* QualifiedNameBinaryEncoding - Part: 6, Chapter: 5.2.2.13, Page: 20 */
 typedef struct UA_QualifiedName {
 	UA_UInt16 namespaceIndex;
-	UA_UInt16 reserved;
+	/*UA_UInt16 reserved; removed by Sten since unclear origin*/
 	UA_String name;
 } UA_QualifiedName;
 UA_TYPE_METHOD_PROTOTYPES(UA_QualifiedName)

+ 3 - 3
src/ua_basictypes.c

@@ -1313,7 +1313,7 @@ UA_TYPE_METHOD_NEW_DEFAULT(UA_StatusCode)
  */
 UA_Int32 UA_QualifiedName_calcSize(UA_QualifiedName const * p) {
 	UA_Int32 length = 0;
-	if (p == NULL) return sizeof(UA_QualifiedName);
+	if (p == UA_NULL) return sizeof(UA_QualifiedName);
 	length += sizeof(UA_UInt16); //qualifiedName->namespaceIndex
 	// length += sizeof(UA_UInt16); //qualifiedName->reserved
 	length += UA_String_calcSize(&(p->name)); //qualifiedName->name
@@ -1347,7 +1347,7 @@ UA_Int32 UA_QualifiedName_init(UA_QualifiedName * p){
 	if(p==UA_NULL)return UA_ERROR;
 	UA_String_init(&(p->name));
 	p->namespaceIndex=0;
-	p->reserved=0;
+	//p->reserved=0;
 	return UA_SUCCESS;
 }
 UA_TYPE_METHOD_NEW_DEFAULT(UA_QualifiedName)
@@ -1357,7 +1357,7 @@ UA_Int32 UA_QualifiedName_copy(UA_QualifiedName const *src, UA_QualifiedName *ds
 	retval |= UA_alloc((void**)&dst,UA_QualifiedName_calcSize(UA_NULL));
 	retval |= UA_String_copy(&(src->name),&(dst->name));
 	retval |= UA_UInt16_copy(&(src->namespaceIndex),&(dst->namespaceIndex));
-	retval |= UA_UInt16_copy(&(src->reserved),&(dst->reserved));
+	//retval |= UA_UInt16_copy(&(src->reserved),&(dst->reserved));
 	return retval;
 
 }