src: Print member's name in CHOICE print
Sometimes, if the choice is a null or integer or ... it's not easy to know what has really been selected without the choice member name. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
This commit is contained in:
parent
b9d517e755
commit
64fdc4cb06
|
@ -1014,11 +1014,9 @@ CHOICE_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Print member's name and stuff */
|
/* Print member's name and stuff */
|
||||||
if(0) {
|
if(cb(elm->name, strlen(elm->name), app_key) < 0
|
||||||
if(cb(elm->name, strlen(elm->name), app_key) < 0
|
|| cb(": ", 2, app_key) < 0)
|
||||||
|| cb(": ", 2, app_key) < 0)
|
return -1;
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return elm->type->print_struct(elm->type, memb_ptr, ilevel,
|
return elm->type->print_struct(elm->type, memb_ptr, ilevel,
|
||||||
cb, app_key);
|
cb, app_key);
|
||||||
|
|
Loading…
Reference in New Issue