media/webrtc/signaling/src/sipcc/include/cc_debug.h

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/media/webrtc/signaling/src/sipcc/include/cc_debug.h	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,42 @@
     1.4 +/* This Source Code Form is subject to the terms of the Mozilla Public
     1.5 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.6 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.7 +
     1.8 +#ifndef CC_DEBUG_H_
     1.9 +#define CC_DEBUG_H_
    1.10 +#include "cc_types.h"
    1.11 +#include <cpr_stdio.h>
    1.12 +
    1.13 +extern cc_int32_t VCMDebug;
    1.14 +extern cc_int32_t PLATDebug;
    1.15 +
    1.16 +#ifndef PLAT_ERROR
    1.17 +#define PLAT_ERROR(format, ...) CSFLogError("plat" , format , ## __VA_ARGS__ )
    1.18 +#endif
    1.19 +
    1.20 +#ifndef VCM_ERR
    1.21 +#define VCM_ERR(format, ...) CSFLogError("vcm" , format , ## __VA_ARGS__ )
    1.22 +#endif
    1.23 +
    1.24 +#ifndef VCM_DEBUG
    1.25 +#define VCM_DEBUG(format, ...) CSFLogDebug("vcm" , format , ## __VA_ARGS__ )
    1.26 +#endif
    1.27 +
    1.28 +
    1.29 +//DEBUG message prefixes
    1.30 +#define PLAT_F_PREFIX "PLAT : %s : "
    1.31 +#define PLAT_A_F_PREFIX "PLAT : %s : %s :"
    1.32 +#define PLAT_L_C_F_PREFIX "PLAT :  %d/%d : %s : " // line/call/fname as arg
    1.33 +#define VCM_F_PREFIX "VCM : %s : "
    1.34 +#define VCM_A_F_PREFIX "VCM : %s : %s :"
    1.35 +#define VCM_L_C_F_PREFIX "%s :  %d/%d : %s : " // line/call/fname as arg
    1.36 +#define PLAT_F_PREFIX_ARGS(msg_name, func_name) msg_name, func_name
    1.37 +#define PLAT_L_C_F_PREFIX_ARGS(msg_name, line, call_id, func_name) \
    1.38 +    msg_name, line, call_id, func_name
    1.39 +
    1.40 +
    1.41 +//
    1.42 +#define PLAT_API "PLAT_API" // platform API
    1.43 +#define VCM_API  "VCM_API"  // vcm api
    1.44 +
    1.45 +#endif /* CC_DEBUG_H_ */

mercurial