diff options
author | Akira TAGOH <akira@tagoh.org> | 2012-12-10 19:03:08 +0900 |
---|---|---|
committer | Akira TAGOH <akira@tagoh.org> | 2012-12-10 19:03:08 +0900 |
commit | a9bee062439fa6992919d964832415fdd67f8d09 (patch) | |
tree | 419fbff067691fb2d7b8ec28babb042876cea88a | |
parent | 5793da78b90c819e9b7192877faf4f5f2e085adf (diff) |
Don't output an error message even if no data is set in lt_error_t
-rw-r--r-- | liblangtag/lt-error.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/liblangtag/lt-error.c b/liblangtag/lt-error.c index f160e23..091ad67 100644 --- a/liblangtag/lt-error.c +++ b/liblangtag/lt-error.c @@ -158,7 +158,8 @@ void lt_error_clear(lt_error_t *error) { if (error) { - lt_mem_delete_ref(&error->parent, error->data); + if (error->data) + lt_mem_delete_ref(&error->parent, error->data); error->data = NULL; } } |