PostGIS  2.1.10dev-r@@SVN_REVISION@@
static void cu_errorreporter ( const char *  fmt,
va_list  ap 
)
static

CUnit error handler Log message in a global var instead of printing in stderr.

CAUTION: Not stop execution on lwerror case !!!

This is a GNU extension. Dunno how to handle errors here.

Definition at line 235 of file liblwgeom/cunit/cu_tester.c.

References cu_error_msg, lw_vasprintf(), lwfree(), and MAX_CUNIT_ERROR_LENGTH.

Referenced by main().

236 {
237  char *msg;
238 
242  if (!lw_vasprintf (&msg, fmt, ap))
243  {
244  va_end (ap);
245  return;
246  }
247 
248  strncpy(cu_error_msg, msg, MAX_CUNIT_ERROR_LENGTH);
249  lwfree(msg);
250 }
void lwfree(void *mem)
Definition: lwutil.c:190
tuple fmt
Definition: pixval.py:92
int lw_vasprintf(char **result, const char *format, va_list args)
Definition: vsprintf.c:148
#define MAX_CUNIT_ERROR_LENGTH
char cu_error_msg[MAX_CUNIT_ERROR_LENGTH+1]

Here is the call graph for this function:

Here is the caller graph for this function: