aboutsummaryrefslogtreecommitdiffstats
path: root/skeletons
diff options
context:
space:
mode:
authorLev Walkin <vlm@lionet.info>2013-03-19 16:16:28 -0700
committerLev Walkin <vlm@lionet.info>2013-03-19 16:16:28 -0700
commit46755ce2001c5ea85b7a3cab6bbfbb729cc4771b (patch)
treed3e0445e62d9a7eae13c0ceb150ec36c3771b312 /skeletons
parent5036c808a105b212d21e7be01b82d7f12e6c1e00 (diff)
allow td to be absent when printing out debug
Diffstat (limited to 'skeletons')
-rw-r--r--skeletons/asn_codecs.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/skeletons/asn_codecs.h b/skeletons/asn_codecs.h
index 4a251d94..e5600142 100644
--- a/skeletons/asn_codecs.h
+++ b/skeletons/asn_codecs.h
@@ -62,7 +62,7 @@ typedef struct asn_enc_rval_s {
tmp_error.encoded = -1; \
tmp_error.failed_type = td; \
tmp_error.structure_ptr = sptr; \
- ASN_DEBUG("Failed to encode element %s", td->name); \
+ ASN_DEBUG("Failed to encode element %s", td ? td->name : ""); \
return tmp_error; \
} while(0)
#define _ASN_ENCODED_OK(rval) do { \
@@ -92,7 +92,7 @@ typedef struct asn_dec_rval_s {
asn_dec_rval_t tmp_error; \
tmp_error.code = RC_FAIL; \
tmp_error.consumed = 0; \
- ASN_DEBUG("Failed to decode element %s", td->name); \
+ ASN_DEBUG("Failed to decode element %s", td ? td->name : ""); \
return tmp_error; \
} while(0)
#define _ASN_DECODE_STARVED do { \