Unit tests to ensure robust handling of bogus params to convenience funcs

plus fixes for the bugs they exposes.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@3416 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
ejakowatz
2003-06-03 23:22:08 +00:00
parent 575526ff34
commit 0cc48ce6f9
5 changed files with 141 additions and 80 deletions
+1 -1
View File
@@ -667,7 +667,7 @@ status_t BMessage::PopSpecifier()
return fBody->FindData<TYPE>(name, index, p, TYPESPEC); \
} \
status_t BMessage::Replace ## fnName(const char* name, TYPE val) \
{ return ReplaceData(name, TYPESPEC, 0, &val, sizeof(TYPE)); } \
{ return Replace ## fnName(name, 0, val); } \
status_t BMessage::Replace ## fnName(const char *name, int32 index, TYPE val) \
{ return fBody->ReplaceData<TYPE>(name, index, val, TYPESPEC); } \
bool BMessage::Has ## fnName(const char* name, int32 n) const \