Guard against a message retrieval before library initialization.

This commit is contained in:
Vreixo Formoso Lopes 2007-10-19 07:36:14 +00:00
parent b9c4f7ad1d
commit 2b92fbc31a
1 changed files with 3 additions and 0 deletions

View File

@ -121,6 +121,9 @@ int iso_msgs_obtain(char *minimum_severity,
char *textpt, *sev_name;
struct libiso_msgs_item *item = NULL;
if (libiso_messenger == NULL)
return 0;
ret = libiso_msgs__text_to_sev(minimum_severity, &minimum_sevno, 0);
if (ret <= 0)
return 0;