]> git.stg.codes - stg.git/blobdiff - stglibs/smux.lib/constr_CHOICE.c
Ticket 37. '../stglibs/common.lib/strptime.cpp' added in the
[stg.git] / stglibs / smux.lib / constr_CHOICE.c
index b8d6fa9a7f210585e851f8f1ab3cadf1d8fe4923..a20a0505dd11692897e638dd8aaac1b394725a16 100644 (file)
@@ -1020,7 +1020,7 @@ CHOICE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel,
 
 void
 CHOICE_free(asn_TYPE_descriptor_t *td, void *ptr, int contents_only) {
-       asn_CHOICE_specifics_t *specs = (asn_CHOICE_specifics_t *)td->specifics;
+       asn_CHOICE_specifics_t *specs = td ? (asn_CHOICE_specifics_t *)td->specifics : NULL;
        int present;
 
        if(!td || !ptr)