Changeset 55 in libcf for trunk/src/cf_debug.c


Ignore:
Timestamp:
04/06/13 21:44:24 (11 years ago)
Author:
cheese
Message:

#1 arrange definition and fix for windows

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/cf_debug.c

    r53 r55  
    2222#define IS_READABLE_CHAR(__c)       (' ' <= __c && __c <= '~')
    2323
    24 #define CHECK_INVALID_CTX(__ctx)            \
     24#define ASSERT_CTX(__ctx)                   \
    2525    if (__ctx == NULL)                      \
    2626        return CF_ERROR_DEBUG_INVALID_CTX
     
    8282    CF_DEBUG_CTX * context = (CF_DEBUG_CTX *) ctx;
    8383
    84     CHECK_INVALID_CTX (ctx);
     84    ASSERT_CTX (ctx);
    8585
    8686    strncpy (context->file, file, strlen (file));
     
    156156    CF_DEBUG_CALLSTACK  * next = NULL;
    157157
    158     CHECK_INVALID_CTX (ctx);
     158    ASSERT_CTX (ctx);
    159159
    160160    if (context->fp != NULL)
     
    297297    CF_DEBUG_CALLSTACK  * push = NULL;
    298298
    299     CHECK_INVALID_CTX (ctx);
     299    ASSERT_CTX (ctx);
    300300
    301301    push = (CF_DEBUG_CALLSTACK *) calloc (sizeof (CF_DEBUG_CALLSTACK), 1);
     
    366366    CF_DEBUG_CALLSTACK  * pop = NULL;
    367367
    368     CHECK_INVALID_CTX (ctx);
     368    ASSERT_CTX (ctx);
    369369
    370370    pop = context->callstack.caller;
Note: See TracChangeset for help on using the changeset viewer.