[asterisk-bugs] [JIRA] (ASTERISK-30001) db: Removing nonexistent entries shows "Database entry removed"

Friendly Automation (JIRA) noreply at issues.asterisk.org
Thu Jun 30 19:29:09 CDT 2022


    [ https://issues.asterisk.org/jira/browse/ASTERISK-30001?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=259591#comment-259591 ] 

Friendly Automation commented on ASTERISK-30001:
------------------------------------------------

Change 18718 merged by Friendly Automation:
db: Notify user if deleted DB entry didn't exist.

[https://gerrit.asterisk.org/c/asterisk/+/18718|https://gerrit.asterisk.org/c/asterisk/+/18718]

> db: Removing nonexistent entries shows "Database entry removed"
> ---------------------------------------------------------------
>
>                 Key: ASTERISK-30001
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-30001
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: General
>    Affects Versions: 18.10.0
>            Reporter: N A
>            Severity: Trivial
>
> If you try to remove an AstDB entry that doesn't exist from the CLI, you're always told it was deleted:
> {noformat}
> pbxdev*CLI> database del foo bar
> Database entry removed.
> pbxdev*CLI> database del foo bar
> Database entry removed.
> pbxdev*CLI> database del foo bar
> Database entry removed.
> pbxdev*CLI> database del foo bar
> Database entry removed.
> {noformat}
> (there is no further output, even with core debug 10).
> I initially thought that perhaps it simply always says that, but looking at the code, there is a branch to say that the entry didn't exist: https://github.com/asterisk/asterisk/blob/master/main/db.c#L683
> So there is a bug with ast_db_del not returning the proper value when entries do not exist.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list