NXSL: isInstance fixed in Table::addColumn()
authorAlex Kirhenshtein <alk@netxms.org>
Fri, 28 Apr 2017 16:36:53 +0000 (12:36 -0400)
committerAlex Kirhenshtein <alk@netxms.org>
Fri, 28 Apr 2017 16:37:30 +0000 (12:37 -0400)
src/libnxsl/table.cpp

index 016fdad..20f1e63 100644 (file)
@@ -98,7 +98,7 @@ NXSL_METHOD_DEFINITION(Table, addColumn)
    {
       if (!argv[3]->isInteger())
          return NXSL_ERR_NOT_INTEGER;
-      isInstance = (argv[1]->getValueAsInt32() != 0);
+      isInstance = (argv[3]->getValueAsInt32() != 0);
    }
 
    *result = new NXSL_Value((INT32)((Table *)object->getData())->addColumn(argv[0]->getValueAsCString(), dataType, displayName, isInstance));