Skip to content
Snippets Groups Projects
Commit 9eb25179 authored by Sebastien Ponce's avatar Sebastien Ponce Committed by Steven Murray
Browse files

several small fixes for defects identified by Coverity. Mainly around uncaught...

several small fixes for defects identified by Coverity. Mainly around uncaught exceptions and secure coding
parent 7c4739dc
Branches
Tags
No related merge requests found
......@@ -129,6 +129,14 @@ typedef char* bitvct; /* bit vector type definition */
INC_PTR(ptr,strlen(str)+1); \
}
#define marshall_STRINGN(ptr,str,n) { (void) strncpy((char*)(ptr),(char*)(str),n); \
((char*)(ptr))[n-1] = 0; \
if (strlen(str)+1 > n) \
INC_PTR(ptr,n); \
else \
INC_PTR(ptr,strlen(str)+1); \
}
#define unmarshall_STRING(ptr,str) { (void) strcpy((char*)(str),(char*)(ptr)); \
INC_PTR(ptr,strlen(str)+1); \
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment