Browse Source

NumericRanges with a single entry in a dimensions must be a single value and not the same separated with a colon

Julius Pfrommer 8 years ago
parent
commit
3142cddfc2
4 changed files with 7 additions and 6 deletions
  1. 1 2
      include/ua_constants.h
  2. 1 1
      src/server/ua_nodes.h
  3. 1 1
      src/server/ua_server_utils.c
  4. 4 2
      src/ua_types.c

+ 1 - 2
include/ua_constants.h

@@ -1,5 +1,4 @@
-/*
- * Copyright (C) 2013-2015 the contributors as stated in the AUTHORS file
+/* Copyright (C) 2013-2016 the contributors as stated in the AUTHORS file
  *
  * This file is part of open62541. open62541 is free software: you can
  * redistribute it and/or modify it under the terms of the GNU Lesser General

+ 1 - 1
src/server/ua_nodes.h

@@ -124,7 +124,7 @@ typedef struct {
  * Consistency between the array dimensions attribute in the variable and its
  * :ref:`variabletypenode` is ensured. */
 /* Indicates whether a variable contains data inline or whether it points to an
-   external data source */
+ * external data source */
 typedef enum {
     UA_VALUESOURCE_DATA,
     UA_VALUESOURCE_DATASOURCE

+ 1 - 1
src/server/ua_server_utils.c

@@ -20,7 +20,7 @@ readDimension(UA_Byte *buf, size_t buflen, UA_NumericRangeDimension *dim) {
         return 0;
 
     /* invalid range */
-    if(dim->min > dim->max)
+    if(dim->min >= dim->max)
         return 0;
     
     return progress + progress2;

+ 4 - 2
src/ua_types.c

@@ -16,10 +16,12 @@
 /* Static definition of NULL type instances */
 UA_EXPORT const UA_String UA_STRING_NULL = {.length = 0, .data = NULL };
 UA_EXPORT const UA_ByteString UA_BYTESTRING_NULL = {.length = 0, .data = NULL };
-UA_EXPORT const UA_Guid UA_GUID_NULL = {.data1 = 0, .data2 = 0, .data3 = 0, .data4 = {0,0,0,0,0,0,0,0}};
+UA_EXPORT const UA_Guid UA_GUID_NULL = {.data1 = 0, .data2 = 0, .data3 = 0,
+                                        .data4 = {0,0,0,0,0,0,0,0}};
 UA_EXPORT const UA_NodeId UA_NODEID_NULL = {0, UA_NODEIDTYPE_NUMERIC, {0}};
 UA_EXPORT const UA_ExpandedNodeId UA_EXPANDEDNODEID_NULL = {
-    .nodeId = { .namespaceIndex = 0, .identifierType = UA_NODEIDTYPE_NUMERIC, .identifier.numeric = 0 },
+    .nodeId = { .namespaceIndex = 0, .identifierType = UA_NODEIDTYPE_NUMERIC,
+                .identifier.numeric = 0 },
     .namespaceUri = {.length = 0, .data = NULL}, .serverIndex = 0 };
 
 static void UA_deleteMembers_noInit(void *p, const UA_DataType *type);