summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--funcs/func_presencestate.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/funcs/func_presencestate.c b/funcs/func_presencestate.c
index f1af8b4fd..ad452df66 100644
--- a/funcs/func_presencestate.c
+++ b/funcs/func_presencestate.c
@@ -255,7 +255,9 @@ static enum ast_presence_state custom_presence_callback(const char *data, char *
char *_message;
char *_subtype;
- ast_db_get(astdb_family, data, buf, sizeof(buf));
+ if (ast_db_get(astdb_family, data, buf, sizeof(buf))) {
+ return AST_PRESENCE_NOT_SET;
+ }
if (parse_data(buf, &state, &_subtype, &_message, &_options)) {
return AST_PRESENCE_INVALID;