Author: sayer
Date: 2009-02-10 12:40:55 +0100 (Tue, 10 Feb 2009)
New Revision: 1258
Modified:
branches/1.1/core/AmArg.cpp
Log:
fix size() for struct type (backport from trunk)
Modified: branches/1.1/core/AmArg.cpp
===================================================================
--- branches/1.1/core/AmArg.cpp 2009-02-10 11:30:48 UTC (rev 1257)
+++ branches/1.1/core/AmArg.cpp 2009-02-10 11:40:55 UTC (rev 1258)
@@ -182,8 +182,14 @@
const size_t AmArg::size() const {
if ((Array != type) && (Struct != type))
throw TypeMismatchException();
+ if (Array == type)
+ return v_array->size();
- return v_array->size();
+ return v_array->size();
+ if (Struct == type)
+ return v_struct->size();
+
+ throw TypeMismatchException();
}
AmArg& AmArg::get(size_t idx) {
_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev